
acm练习总结
l1905
这个作者很懒,什么都没留下…
展开
-
1关于字符串输出
InputEach article consists of just one line, and all the letters are in lowercase. You just have to count the number of each letter, so do not pay attention to other characters. The length of articl原创 2012-12-07 11:32:20 · 408 阅读 · 0 评论 -
小数化分数2
杭电地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=12小数化分数2Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)T原创 2013-05-03 16:13:41 · 905 阅读 · 0 评论 -
又见gcd( 最小公约数)
杭电:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=6又见GCDTime Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submissio原创 2013-05-02 14:49:46 · 657 阅读 · 0 评论 -
找新朋友(公约数系列问题)
杭电地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=8找新朋友Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Tota原创 2013-05-02 18:50:29 · 664 阅读 · 0 评论 -
cake
此文参考网上的代码。。。刚开始有些没想通。。。组要还是需要自己动手切一下蛋糕最好网上连接:http://blog.youkuaiyun.com/ilovexiaohao/article/details/8590583杭电题地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=4原创 2013-05-02 09:51:21 · 710 阅读 · 0 评论 -
该刷一段时间的题了
貌似最近过的混混沌沌。。。。。。。。大三下学期马上就跑了。。该刷一段时间的acm了。。。把基础打好。。。。。以后一定会用到的。。。。。不能浮沙筑高台啊此文为证:每天至少2+题,并且更新博客。。。。说道做到 。。。。打死拖延症原创 2013-05-02 09:05:55 · 507 阅读 · 0 评论 -
最小公倍数
杭电题库地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=1比较简单 就不过多说了。#include using namespace std;int lcm(int a,int b){ int max = (a >= b?a:b),min = (原创 2013-05-02 09:14:20 · 480 阅读 · 0 评论 -
贪心算法+保留小数点位数
Input输入数据首先包含一个正整数C,表示有C组测试用例,每组测试用例的第一行是两个整数n和m(0 Output对于每组测试数据,请输出能够购买大米的最多重量(你可以假设经费买不光所有的大米)。每个实例的输出占一行,保留2位小数。 Sample Input17 23 34 4 Sample Ou原创 2012-12-16 11:51:14 · 1165 阅读 · 0 评论 -
关于"保留小数点后几位数字“
原文地址:http://www.cnblogs.com/krisdy/archive/2009/04/17/1438402.html 刚刚做了一个杭电的题目,上面有个要求是输出时要求保留小数点后几位数字后然后输出。既然又看到了这个熟悉的字眼和要求,那就在这里稍微写些东西算是记载一下吧,也算是一个小总结,不过这里总结的只是目前我所想到的,后续还有待补充。】1. C++中格式控制转载 2012-12-16 11:55:21 · 7930 阅读 · 0 评论 -
温习辗转相除法
原文地址:杭电 1.2.2 hide handkerchiefhide handkerchiefTime Limit: 10000/3000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1708 A转载 2012-12-10 22:04:02 · 377 阅读 · 0 评论 -
(3)IBM Minus One
InputThe input starts with the integer n on a line by itself - this is the number of strings to follow. The following n lines each contain one string of at most 50 upper-case letters.原创 2012-12-09 15:38:58 · 371 阅读 · 0 评论 -
(2)字符转转化的题
Problem DescriptionSince all we know the ASCII code, your job is simple: input numbers and output corresponding messages. InputThe first line contains one integer T (1The input will原创 2012-12-07 12:13:16 · 772 阅读 · 0 评论 -
Leftmost Digit(数论)
杭电地址:http://acm.hdu.edu.cn/game/entry/problem/show.php?chapterid=2§ionid=1&problemid=11Leftmost DigitTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others转载 2013-05-03 17:37:47 · 635 阅读 · 0 评论