#include <iostream.h>
#include <fstream.h>
#include <stdio.h>
void writeinfile(int n);
void main()
{
int n,k,m,l,sum=0;
n=100;
/**********Program**********/
for(m=2;m<=n;m++)
{
for(k=2;k<m;k++)
{
l=m%k;
if(l==0)
{break;}
}
if(k==m)
sum+=m;
}
cout<<sum<<endl;
/********** End **********/
writeinfile(sum);
}
void writeinfile(int n)
{
fstream myfile;
myfile.open(" f.txt" ,ios::out);
myfile<<n<<endl;
myfile.close();
}