#include <iostream>
#include <iomanip>
#include <vector>
#include <algorithm>
#include <string>
#include <cstdio>
#include <cmath>
#include <map>
using namespace std;

int main()
{
	int n;

	while(cin >> n){
		int c2 = 0;
		for (int i = 1; i <= n; ++i){
			int c = 0;
			for (int j = 1; j <= i; ++j)
			{
				if(i % j == 0){
					c++;
				}
			}
			if(c == 2){
				c2++;
			}
		}
		cout << c2 << endl;
	}
}