2015年9月22日
摘要: 样例输入:4样例输出:10 11 12 19 16 13 28 15 14 37 6 5 4#include #include #include int main(){ int a[50][50]; int i,j,x,y,cot,n;... 阅读全文
posted @ 2015-09-22 20:44 cnxo 阅读(131) 评论(0) 推荐(0) 编辑
摘要: /**有n个灯,编号为1-n。第一个人把所以灯打开,第二个人按下 所有编号为2的倍数的开关,第三个人按下3的倍数的开关,依次类推, 一共有k个人,问最后有哪些灯开着? 样例输入: 7 3 样例输出: 1 5 6 7 **/#include #include #include int... 阅读全文
posted @ 2015-09-22 19:57 cnxo 阅读(214) 评论(0) 推荐(0) 编辑