#include <bits/stdc++.h>
using namespace std;
bool isPrime(int p) {
  if (p <= 1) return false;
  for (int i = 2; i * i <= p; i += 2) {
    if (p % i == 0) return false;
  }
  return true;
}
int main() {
  int n, p, count = 0;
  cin >> n;
  for (int i = 0; i < n; i++) {
    if (isPrime(p)) count++;
  }
  cout << count << endl;
}
