随笔分类 -  STL

2017校招编程题-网易
摘要:合唱团 地牢逃脱 思路: 看了牛客网的toraoh大神的题解,才明白这道题,emmm...不是我一开始想的那个意思。而是起始点到终点的距离都是最短路径,只不过这个终点不定,想知道去哪个终点的最短路径最大,Max(Min),要这个最大的路径值。 所以思路就是,通过BFS搜索去每个点的最短路径,涉及到D 阅读全文
posted @ 2018-03-25 16:11 lpt 阅读(226) 评论(0) 推荐(0)
1.1.4 PROB Greedy Gift Givers
摘要:Greedy Gift GiversA group of NP (2 ≤ NP ≤ 10) uniquely named friends has decided to exchange gifts of money. Each of these friends might or might not ... 阅读全文
posted @ 2014-11-30 10:06 lpt 阅读(242) 评论(0) 推荐(0)
hdu 4022 Bombing
摘要:BombingTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 65768/65768 K (Java/Others)Total Submission(s): 2650Accepted Submission(s): 990Problem Desc... 阅读全文
posted @ 2014-08-28 13:56 lpt 阅读(190) 评论(0) 推荐(0)
ZOJ 1259 Rails
摘要:stack的应用 1 #include 2 #include 3 #include 4 using namespace std; 5 int goal[1005]; 6 int d[1005]; 7 stacks; 8 int main() 9 {10 freopen("input.txt"... 阅读全文
posted @ 2014-07-23 01:13 lpt 阅读(365) 评论(0) 推荐(0)
hdu 2072 单词数
摘要:set的应用 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 int main() 7 { 8 freopen("input.txt","r",stdin); 9 string s,s1;10 ... 阅读全文
posted @ 2014-07-23 01:12 lpt 阅读(119) 评论(0) 推荐(0)
hdu 1004 Let the Balloon Rise
摘要:map的应用 1 #include 2 #include 3 #include 4 #include 5 using namespace std; 6 int main() 7 { 8 freopen("input.txt","r",stdin); 9 mapballoons;10 ... 阅读全文
posted @ 2014-07-23 01:09 lpt 阅读(102) 评论(0) 推荐(0)