#include<iostream> #include<cmath> using namespace std; int main() { int L,s=0,s2=0; bool flag=0; cin>>L; for(int i=2;i<L;i++) { for(int j=0;j<sqrt(i);j++) { if(i%j==0) flag=1; else flag=0; s+=flag; } if(s==0) cout<<i<<endl; s2++; s=0; } cout<<s2; }