上一页 1 ··· 24 25 26 27 28 29 30 31 32 ··· 36 下一页
摘要: 感觉这个题 是真的恶心 本来单纯就递归写,发现好难 后来用数组记录 然后考虑 指数为 奇和偶数 分别 <0 和 > 进制的情况 其实 用进制数为3 大概讨论四种情况就可以了 由于最近就是在划水,就随便写了写代码 也没好好修改,大概过了 #include<bits/stdc++.h> using na 阅读全文
posted @ 2017-08-30 14:03 Draymonder 阅读(274) 评论(0) 推荐(0) 编辑
摘要: 题意 : 英语不好要遭殃。。。 给你一个图,找最短路。但是有个非一般的的条件:如果a,b之间有路,且你选择要走这条路,那么必须保证a到终点的所有路都小于b到终点的一条路。问满足这样的路径条数 有多少。。。就这个条件,看懂的时候估计都个把小时了 简化一下 a b之间如果有路 就是 1 -> 2 大于 阅读全文
posted @ 2017-08-30 11:20 Draymonder 阅读(195) 评论(0) 推荐(0) 编辑
摘要: 本来我写的对的 我就多手写了个 ios::sync_with_stdio(false); 我程序里面用了cin 还有scanf 本来想偷偷懒 我就说 我查了半天错 根本找不到的啊... 后来交了几次 发现一直有RE 才发现...... 我好笨 //最短路 dijkstral #include<bit 阅读全文
posted @ 2017-08-26 15:44 Draymonder 阅读(252) 评论(0) 推荐(0) 编辑
摘要: 倒腾了一个小时 自己也没去看网上的 总算自己能写出来模板了 kruskal prim 阅读全文
posted @ 2017-08-26 15:02 Draymonder 阅读(180) 评论(0) 推荐(0) 编辑
摘要: 详细见:http://blog.csdn.net/nk_test/article/details/46242401 #include<bits/stdc++.h> using namespace std; const int maxn = 1e7; bool vis[maxn]; int prime 阅读全文
posted @ 2017-08-25 15:38 Draymonder 阅读(286) 评论(0) 推荐(0) 编辑
摘要: Two Paths Problem Description You are given a undirected graph with n nodes (numbered from 1 to n) and m edges. Alice and Bob are now trying to play a 阅读全文
posted @ 2017-08-25 10:13 Draymonder 阅读(235) 评论(0) 推荐(0) 编辑
摘要: 快速读入? 不知道 反正只是贴过来的 以后或许会用到? #define FI(n) FastIO::read(n) namespace FastIO { const int SIZE = 1 << 16; char buf[SIZE], obuf[SIZE], str[60]; int bi = S 阅读全文
posted @ 2017-08-24 22:01 Draymonder 阅读(349) 评论(0) 推荐(0) 编辑
摘要: Schedule Problem Description There are N schedules, the i-th schedule has start time si and end time ei (1 <= i <= N). There are some machines. Each t 阅读全文
posted @ 2017-08-24 21:46 Draymonder 阅读(324) 评论(0) 推荐(0) 编辑
摘要: 这种博弈题 都是打表找规律 可我连怎么打表都不会 这个是凑任务的吧....以后等脑子好些了 再琢磨吧 就是斐波那契数列中的数 是必败态 #include<bits/stdc++.h> using namespace std; map<long long ,int> mp; void init() { 阅读全文
posted @ 2017-08-23 13:22 Draymonder 阅读(181) 评论(0) 推荐(0) 编辑
摘要: Numbers Time Limit: 4000/2000 MS (Java/Others) Memory Limit: 131072/131072 K (Java/Others)Total Submission(s): 514 Accepted Submission(s): 270 Problem 阅读全文
posted @ 2017-08-23 10:51 Draymonder 阅读(136) 评论(0) 推荐(0) 编辑
上一页 1 ··· 24 25 26 27 28 29 30 31 32 ··· 36 下一页