int main(void)
{
	int x,i,j,k,count;
	scanf("%d",&x);
	count=1;
	for(i=3;i<=x;i+=2)
	{
		k=0;
		for(j=3;j<=sqrt(i);j+=2)
		{
			if(i%j==0)
			{
				k=1;
				break;
			}
		}

		if(k==0) count=count+1;
	}

	printf("%d\n",count);

	return 0;
}