#include <bits/stdc++.h>
using namespace std;
const long long mod = 1e9 + 7;
long long noOfSetBits(long long x) { return __builtin_popcountll(x); }
long long countBits(long long x) { return (long long)log2(x) + 1; }
vector<int> v;
void helper() {
  int n = 3007;
  v.resize(n);
  for (int i = 1; i < n; i++) v[i] = i;
  for (int i = 2; i * i < n; i++) {
    if (v[i] != i) continue;
    for (int j = i * i; j < n; j += i) {
      if (v[j] == j) v[j] = i;
    }
  }
}
int check(int x) {
  int cnt = 0;
  while (x > 1) {
    int t = 0, y = v[x];
    while (x % y == 0 and x > 1) {
      x = x / y;
      t = 1;
    }
    cnt += t;
  }
  return (cnt == 2);
}
int main(int argc, char const *argv[]) {
  ios_base::sync_with_stdio(false);
  long long test = 1, k, x, y, pos, n, i, p, q, r, m, c, a, b;
  helper();
  while (test--) {
    cin >> n;
    long long cnt = 0;
    for (int i = 2; i <= n; i++) {
      if (check(i)) cnt++;
    }
    cout << cnt;
    cout << "\n";
  }
  return 0;
}
