#include <bits/stdc++.h>
using namespace std;
int n;
int ans;
int main() {
  int a[3005];
  fill_n(a, 3005, -1);
  cin >> n;
  int k = 2;
  a[1] = a[2] = -1;
  while (k <= n) {
    for (int i = k; i <= n; i += k) {
      if (i == k) continue;
      if (a[i] == -1) {
        a[i] += 2;
      }
    }
    k++;
  }
  for (int j = 1; j <= n; j++) {
    int t = 0;
    for (int i = 2; i <= n; i++) {
      if (j % i == 0 && a[i] < 0) t++;
    }
    if (t == 2) ans++;
  }
  cout << ans << endl;
  return 0;
}
