#include <bits/stdc++.h>
using namespace std;
int n, i, j, ans;
long long v[3001];
int main() {
  cin >> n;
  for (i = 2; i <= n; i++) {
    if (v[i] == 0) {
      for (j = i * 2; j <= n; j += i) {
        v[j]++;
      }
    } else if (v[i] == 2) {
      ans++;
    }
  }
  cout << ans;
  return 0;
}
