摘要:
这题目测是数据水了。我这种暴力写法显然是可以卡超时的。 假设有2000个点,15000条边,前面10000条不能构成树,后面5000条可以,这种数据显然可以卡超时。 #include <stdio.h> #include <algorithm> #include <string.h> #includ 阅读全文
posted @ 2016-02-14 14:52
Fighting_Heart
阅读(257)
评论(0)
推荐(0)
摘要:
N个点中任意选取四个点,就能产生一个圆内的交点,所以圆内总共有C(N,4)个交点,圆上有N个,相加就可以了。 注意:组合数运算的时候会爆longlong,中间先除一下就可以了。 #include <stdio.h> #include <algorithm> #include <string.h> # 阅读全文
posted @ 2016-02-14 14:50
Fighting_Heart
阅读(202)
评论(0)
推荐(0)
摘要:
想了一下发现是斐波那契数列.....水题 #include <stdio.h> #include <algorithm> #include <string.h> #include <queue> #include <stack> #include <map> #include <vector> us 阅读全文
posted @ 2016-02-14 14:48
Fighting_Heart
阅读(138)
评论(0)
推荐(0)
摘要:
暴力匹配+一点判断 #include <stdio.h> #include <algorithm> #include <string.h> #include <queue> #include <stack> #include <map> #include <vector> using namespa 阅读全文
posted @ 2016-02-14 00:28
Fighting_Heart
阅读(343)
评论(0)
推荐(0)
摘要:
简单构造 #include <stdio.h> #include <algorithm> #include <string.h> #include <queue> #include <stack> #include <map> #include <vector> using namespace st 阅读全文
posted @ 2016-02-14 00:28
Fighting_Heart
阅读(177)
评论(0)
推荐(0)
摘要:
贪心水题 #include <stdio.h> #include <algorithm> #include <string.h> #include <queue> #include <stack> #include <map> #include <vector> using namespace st 阅读全文
posted @ 2016-02-14 00:27
Fighting_Heart
阅读(227)
评论(0)
推荐(0)
摘要:
神奇的构造题,我的思路比较奇葩。搞了好久,看到WA on 91我绝望了,然后自己造数据,找到了错误,总算是AC了,现在是凌晨0:24分,看到AC之后,感动China! 我写的代码无比的长。。。。。应该有很简单的方法吧。。。。。没想到。 #include <stdio.h> #include <alg 阅读全文
posted @ 2016-02-14 00:26
Fighting_Heart
阅读(262)
评论(0)
推荐(0)

浙公网安备 33010602011771号