#include <iostream>
using namespace std;

int main() {
    while(cin) {
        int n;
        cin >> n;
        
        int count = 0;
        for(int i=1; i<=n; i++) {
            int k = 0;
            for(int j=1; j<=i; j++) {
                if(i%j == 0) k++;
            }
            if(k == 2) {
                count ++;
            }
        }
        cout << count << endl;
    }
    return 0;
}