#include <bits/stdc++.h>
using namespace std;
const int MAXN = 3000;
int isPrime[MAXN + 1];
int main() {
  for (int i = 2; i <= MAXN; i++) {
    isPrime[i] = 1;
    for (int j = 2; j < i; j++) {
      if (i % j == 0) isPrime[i] = 0;
    }
  }
  int n;
  cin >> n;
  int ret = 0;
  for (int i = 2; i <= n; i++) {
    int count = 0;
    for (int j = 2; j < i; j++) {
      if (i % j == 0 && isPrime[j]) count++;
    }
    if (count == 2) ret++;
  }
  cout << ret << endl;
  return 0;
}
