摘要: View Code 1 #include <stdio.h> 2 #include<math.h> 3 int prime[1000000]; 4 int main() 5 { 6 int s,max; 7 while(scanf("%d",&max)!=EOF&&max!=0) 8 { 9 s=0;10 prime[0]=prime[1]=0;prime[2]=1;11 for(int i=3;i<max;i++)12 prime[i]=i%2==0?0:1;13 int t=(int)sqrt(max*1.0);.. 阅读全文
posted @ 2013-03-11 23:30 水门 阅读(158) 评论(0) 推荐(0) 编辑