上一页 1 ··· 24 25 26 27 28 29 30 31 32 ··· 38 下一页
摘要: /* 这是我第一次碰到真正意义上,因为cin被卡TLE的情况,甚至取消了cin与stdio的同步,也没有丝毫作用...终于明白大家为什么喜欢用scanf胜过用cin了,以后一定要注意!!!还是用scanf为好 如果仍然被卡,就需要考虑下cout换printf了... 阅读全文
posted @ 2017-08-26 09:25 mofushaohua 阅读(122) 评论(0) 推荐(0)
摘要: #include #include using namespace std;// 邻接格子的坐标const int dx[5] = {-1, 0, 0, 0, 1};const int dy[5] = {0, -1, 0, 1, 0};const int MAX_M ... 阅读全文
posted @ 2017-08-26 09:24 mofushaohua 阅读(109) 评论(0) 推荐(0)
摘要: //挑战P122#include #include using namespace std;const int MAXN = 65010;int notprime[MAXN];int n;typedef long long ll;void init(){ memset... 阅读全文
posted @ 2017-08-26 09:22 mofushaohua 阅读(291) 评论(0) 推荐(0)
摘要: /* 解析见挑战P48-49 法一:递归--复杂度(O(n^2))*/#include typedef long long ll;const int MAX_N = 2e4 + 10;int N, L[MAX_N];using namespace std;void ... 阅读全文
posted @ 2017-08-26 09:20 mofushaohua 阅读(150) 评论(0) 推荐(0)
摘要: /*这题值得一说的是,之前一直没有看懂题目,一直不知道题目是什么意思,后来明白了:一二三四行,就是它标的号码1、2、3、4所在区域的状态每行有4个数字,4个数字若分别为1,分别表示此处有车左转、有车直行、有车右转、人行道有行人于是,剩下的就比较好想了:某块区域只要有人... 阅读全文
posted @ 2017-08-26 09:18 mofushaohua 阅读(163) 评论(0) 推荐(0)
上一页 1 ··· 24 25 26 27 28 29 30 31 32 ··· 38 下一页