#include<iostream>
using namespace std;

int main(){
 int n,i,j,x,counter;
 while (cin >> n) {
  counter = 0;
  
  for (i = 1; i <= n; i++) {
    x = 0;
    
    for (j = 1; j <= i; j++) {
      if (i % j == 0) x++;
    }
    
    if (x == 2) counter++;
  }
  
  cout << counter << endl;
  
 }
 return 0;
}
