#include <bits/stdc++.h>
using namespace std;
const int mod = 1e9 + 7;
const int MAX = 3001;
bool primes[MAX];
void sieve() {
  fill(primes, primes + MAX, true);
  primes[0] = false, primes[1] = false;
  int rcn = sqrt(MAX);
  for (int i = 2; i <= rcn; i++)
    if (primes[i])
      for (int j = 2; j * i < MAX; j++) primes[j * i] = false;
}
inline void JadedBeast() {
  ios::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
}
int main() {
  JadedBeast();
  sieve();
  int number[MAX];
  memset(number, 0, sizeof(number));
  for (int i = 2; i < MAX; i++)
    if (primes[i])
      for (int j = 2; j * i < MAX; j++) number[i * j]++;
  int n, ans = 0;
  cin >> n;
  for (int i = 0; i <= n; i++)
    if (number[i] == 2) ans++;
  cout << ans << endl;
  return 0;
}
