2014年4月12日
摘要: #include#include#includeusing namespace std;struct Point{ double x,r,x1,x2; int visit;}p[10000];bool cmp(struct Point a,struct Point b){ return a.x1>n... 阅读全文
posted @ 2014-04-12 16:47 mnmlist1 阅读(124) 评论(0) 推荐(0) 编辑
摘要: 孪生素数: 所谓孪生素数指的是间隔为 2 的相邻素数,它们之间的距离已经近得不能再近了。若n≥6且n-1和n+1为孪生素数,那么n一定是6的倍数。证明:∵ n-1和n+1是素数 ┈┈┈┈┈ ①∴ n-1和n+1是奇数∴ n是偶数,即n是2的倍数 ┈┈┈┈┈ ②假设n不是3的倍数,得:n=3x+1 或... 阅读全文
posted @ 2014-04-12 12:46 mnmlist1 阅读(338) 评论(0) 推荐(0) 编辑
摘要: //最重要的收获就是懂得了,还可以调用库函数直接对结构体进行排序sort(const void *,const void *,cmp) /* bool cmp(rect c,rect d) { if(c.no!=d.no) { return c.no#include... 阅读全文
posted @ 2014-04-12 11:39 mnmlist1 阅读(129) 评论(0) 推荐(0) 编辑