#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, prime[3000], nc, c;
  while (cin >> n) {
    nc = 0;
    for (int i = 2; i <= 3000; i++) {
      if (prime[i] != 1) {
        for (int j = i * 2; j <= 3000; j += i) {
          prime[j] = 1;
        }
      }
    }
    for (int k = 1; k <= n; k++) {
      c = 0;
      for (int i = 2; i <= n; i++) {
        if (k % i == 0) {
          if (prime[i] != 1) c++;
        }
      }
      if (c == 2) nc++;
    }
    cout << nc << endl;
  }
}
