
哈希表
文章平均质量分 71
清溪浅水
这个作者很懒,什么都没留下…
展开
-
hdu——2002——sort
Problem Description 给你n个整数,请按从大到小的顺序输出其中前m大的数。 Input 每组测试数据有两行,第一行有两个数n,m(0 Output 对每组测试数据按从大到小的顺序输出前m大的数。 Sample Input 5 3 3 -35 92 213 -644 Sample Output 213 92 3 #include #i原创 2014-02-12 10:33:28 · 557 阅读 · 0 评论 -
poj——1496——Equations
Problem Description Consider equations having the following form: a*x1^2+b*x2^2+c*x3^2+d*x4^2=0 a, b, c, d are integers from the interval [-50,50] and any of them cannot be 0. It is consider原创 2014-02-11 20:26:28 · 639 阅读 · 0 评论 -
poj——1280——前m大的数
Problem Description 还记得Gardon给小希布置的那个作业么?(上次比赛的1005)其实小希已经找回了原来的那张数表,现在她想确认一下她的答案是否正确,但是整个的答案是很庞大的表,小希只想让你把答案中最大的M个数告诉她就可以了。 给定一个包含N(N Input 输入可能包含多组数据,其中每组数据包括两行: 第一行两个数N和M, 第二行N个数,表示原创 2014-02-11 21:09:38 · 582 阅读 · 0 评论 -
hdu——3785——寻找大富翁
Problem Description 浙江桐乡乌镇共有n个人,请找出该镇上的前m个大富翁. Input 输入包含多组测试用例. 每个用例首先包含2个整数n(0 n和m同时为0时表示输入结束. Output 请输出乌镇前m个大富翁的财产数,财产多的排前面,如果大富翁不足m个,则全部输出,每组输出占一行. Sample Input 3 1 2 5 -1原创 2014-02-12 11:09:35 · 534 阅读 · 0 评论