//相邻的 2.3......d 之和都要不为素数 # include <algorithm> # include <stdio.h> using namespace std; int num[1010],vis[1010]; int n,m,d,cot; int flag[10010]; void init()//素数打表 { int i,j; for(i=2;i<10010;i++) { if(!flag[i]) for(j=i*i;j<10010;j=j+i) f…
Apple Tree Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 25904 Accepted: 7682 Description There is an apple tree outside of kaka's house. Every autumn, a lot of apples will grow in the tree. Kaka likes apple very much, so he has been…