#include <bits/stdc++.h>
using namespace std;
int primes[5005];
int cum[5005];
int k = 0;
void soe() {
  int state[5001];
  int i, j;
  memset(state, 0, 5001);
  for (i = 2; i * i <= 5005; i++) {
    if (state[i] == 0) {
      for (j = i * i; j <= 5000; j += i) state[j] = 1;
    }
  }
  for (i = 2; i < 5001; i++)
    if (state[i] == 0) primes[k++] = i;
}
int fun(int n) {
  int i, j, count = 0, ans = 0, temp;
  for (i = 1; i <= n; i++) {
    count = 0;
    temp = i;
    for (j = 0; primes[j] * primes[j] <= i; j++) {
      if (temp % primes[j] == 0) {
        count++;
        while (temp % primes[j] == 0) temp = temp / primes[j];
      }
    }
    if (temp != 1) count++;
    if (count == 2) ans += 1;
  }
  return ans;
}
int main() {
  int n, s;
  soe();
  cin >> n;
  s = fun(n);
  cout << s << endl;
  return 0;
}
