#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  long long n;
  long long cnt = 0;
  cin >> (n);
  for (long long i = 6; i <= n; i++) {
    long long k = i;
    long long tmp = 0;
    for (long long j = 2; j * j <= k; j++) {
      if (tmp > 2) break;
      if (k % j == 0) {
        tmp++;
        while (k % j == 0) k /= j;
      }
    }
    if (k > 1) tmp++;
    if (tmp == 2) cnt++;
  }
  cout << cnt << "\n";
}
