#include<bits/stdc++.h> using namespace std; int main() { long long N,h=0; cin>>N; for(int i=2;i<=N;i++) { bool f=0; for(int j=2;j<=sqrt(i);j++) { if(i%j==0) { f=1; } } if(f==0) { h++; } } cout<<h; return 0; }