#include <bits/stdc++.h>
using namespace std;
int prime[3001];
void modifiedSieve() {
  for (int i = 2; i <= 3000; i++) {
    prime[i] = i;
  }
  for (int i = 2; i * i <= 3000; i++) {
    if (prime[i] == i) {
      for (int j = i * i; j <= 3000; j += i) {
        prime[j] = i;
      }
    }
  }
}
int main() {
  modifiedSieve();
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  int n, ans = 0;
  cin >> n;
  if (n > 5) {
    for (int i = 6; i <= n; i++) {
      int j = i, cnt = 0;
      vector<int> store(3000, 0);
      while (j != 1) {
        store[prime[j]]++;
        j = j / prime[j];
      }
      for (auto val : store) {
        if (val > 0) cnt++;
      }
      if (cnt == 2) {
        ans++;
      }
    }
  }
  cout << ans << "\n";
  return 0;
}
