hdu
文章平均质量分 80
utoppia
这个作者很懒,什么都没留下…
展开
-
hdu 1160 FatMouse's Speed
题目描述: FatMouse's SpeedTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 5675 Accepted Submission(原创 2012-10-17 01:06:04 · 642 阅读 · 0 评论 -
hdu 2177 取(2堆)石子游戏
题目描述:取(2堆)石子游戏Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 449 Accepted Submission(s): 273Problem Description有两堆石子,数量任意,可以不同。游戏开始由原创 2012-10-22 19:23:32 · 387 阅读 · 0 评论 -
CERC_2008_Tower(hdu 2971)
PRO IS HERE由 a(n) = 2*a(2)*a(n-1) - a(n-2)let p = 2*a(2);==>a(n) =p*a(n-1) - a(n-2)==>a(n)^2 = p^2*a(n-1)^2 - 2*p*a(n-1)*a(n-2) + a(n-2)^2................(1)let s(n) =sum(a(i) );s原创 2013-04-16 20:51:27 · 853 阅读 · 0 评论 -
hdu 1695 GCD
HUD1695神奇的容斥原理。用到的知识点就是求[1,L]中和n互质的个数。其实就是将n因数分解,然后对于一个质因子p,[1,L]中和P互质的就有L/p个。容斥解决。#include#include#include#include#include#include#include#include#include#includeusing namespace s原创 2013-08-03 11:30:11 · 615 阅读 · 0 评论 -
HDU 1394
Minimum Inversion NumberTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 7907 Accepted Submission(s): 4851Problem DescriptionT原创 2013-08-25 00:20:04 · 585 阅读 · 0 评论 -
HDU 1540
Tunnel WarfareTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3240 Accepted Submission(s): 1252Problem DescriptionDuring the原创 2013-08-25 00:51:00 · 1077 阅读 · 0 评论 -
2011Fuzhou Online HDU4070
按b从大到小排序。#include#include#include#include#includeusing namespace std;#define nMax 100010struct T{ int a,b; void read() { scanf("%d%d",&a,&b); }};T s[nMax];int cmp(T u,T v) { retu原创 2013-08-25 14:41:44 · 680 阅读 · 0 评论 -
2011 Fuzhou Online HDU 4068
暴力搜索。#include#include#include#include#includeusing namespace std;#define nMax 30string s[nMax];int v[nMax][nMax];int vis[nMax];#define CLR(a) memset((a),0,sizeof((a)))int ok,n;int原创 2013-08-25 14:40:30 · 619 阅读 · 0 评论 -
HDU 1007 Quoit Design
最近点对 。#include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define dbg(x) cerr << "__LINE__原创 2013-11-10 12:56:53 · 819 阅读 · 0 评论 -
HDU 1011 Starship Troopers
树形dp#include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define dbg(x) cerr << "Line:" << __L原创 2013-11-10 13:53:54 · 770 阅读 · 0 评论 -
HDU 1022 Train Problem I
栈模拟#include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define dbg(x) cerr << "Line:" << __LI原创 2013-11-10 14:24:07 · 653 阅读 · 0 评论 -
HDU 1023 Train Problem II
大数 卡特兰数#include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define dbg(x) cerr << "Line:"原创 2013-11-10 15:01:20 · 676 阅读 · 0 评论 -
HDU 1027 Ignatius and the Princess II
全排列,next_permutation#include #include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define原创 2013-11-10 16:03:55 · 634 阅读 · 0 评论 -
HDU 1025 Constructing Roads In JGShining's Kingdom
LIS#include #include #include #include #include using namespace std;#define sf scanf#define pf printf#define rep(i,n) for(int (i)=0;(i)<(n);(i)++)#define dbg(x) cerr << "Line:" << __LI原创 2013-11-10 15:55:15 · 527 阅读 · 0 评论 -
2012 Tianjing Online (HDU4278 - 4287)
4278 Faulty Odometer70.17%(748/1066)4279 Number27.74%(713/2570) 4281 Judges' response56.48%(266/471)4282 A very hard mathematic problem29.56%(107原创 2013-12-03 16:31:44 · 654 阅读 · 0 评论 -
HDU 1296
表达式求值,蛮有意思的,某年校赛就出这题了呢。。。依然顺手。。。哈哈。。。就算退役了心依然不死呢。。。#include#include#include#includeusing namespace std;int const nMax = 10100;#define sf scanf#define pf printf#define rep(i,n) for(in原创 2013-12-13 23:02:40 · 1038 阅读 · 0 评论 -
hdu 2176 取(m堆)石子游戏
题目描述: 取(m堆)石子游戏Time Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 805 Accepted Submission(s): 479Problem Description原创 2012-10-22 19:40:52 · 854 阅读 · 0 评论 -
hdu 3075 Print Article
题目描述:Print ArticleTime Limit: 9000/3000 MS (Java/Others) Memory Limit: 131072/65536 K (Java/Others)Total Submission(s): 2485 Accepted Submission(s): 815Problem DescriptionZero原创 2012-10-22 00:05:15 · 664 阅读 · 0 评论 -
hdu 1171 Big Event in HDU
题目描述:Big Event in HDUTime Limit: 10000/5000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 14161 Accepted Submission(s): 4979Problem Description原创 2012-10-17 18:50:33 · 397 阅读 · 0 评论 -
hdu 1176 免费馅饼
题目描述:免费馅饼Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 15025 Accepted Submission(s): 4979Problem Description都说天上不会掉馅饼,但有一原创 2012-10-17 19:25:23 · 357 阅读 · 0 评论 -
hdu 1260 Tickets
题目描述:TicketsTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 560 Accepted Submission(s): 280Problem DescriptionJesus, what a原创 2012-10-17 22:51:41 · 759 阅读 · 0 评论 -
hdu 1203 I NEED A OFFER!
题目描述:I NEED A OFFER!Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 10310 Accepted Submission(s): 3858Problem DescriptionSp原创 2012-10-17 20:24:16 · 326 阅读 · 0 评论 -
hdu 1284 钱币兑换问题
题目描述:钱币兑换问题Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3147 Accepted Submission(s): 1769Problem Description在一个国家仅有1分,2分原创 2012-10-17 23:19:07 · 344 阅读 · 0 评论 -
hdu 1421 搬寝室
题目描述:搬寝室Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 10056 Accepted Submission(s): 3370Problem Description搬寝室是很累的,xhd深有体原创 2012-10-18 00:23:14 · 400 阅读 · 0 评论 -
hdu 2084 数塔
题目描述:数塔Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11593 Accepted Submission(s): 6969Problem Description在讲述DP算法的时候,一个经典原创 2012-10-19 00:01:24 · 334 阅读 · 0 评论 -
hdu 1978 How many ways
题目描述:How many waysTime Limit: 3000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1458 Accepted Submission(s): 904Problem Description这是一个简单原创 2012-10-18 23:14:19 · 312 阅读 · 0 评论 -
hdu 2059 龟兔赛跑
题目描述:龟兔赛跑Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 7149 Accepted Submission(s): 2744Problem Description据说在很久很久以前,可怜的兔原创 2012-10-18 23:52:58 · 448 阅读 · 0 评论 -
hdu 2159 FATE
题目描述:FATETime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 4124 Accepted Submission(s): 1843Problem Description最近xhd正在玩一款叫做FA原创 2012-10-19 00:14:43 · 328 阅读 · 0 评论 -
hdu 1789 Doing Homework again
题目描述:Doing Homework againTime Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3140 Accepted Submission(s): 1819Problem Description原创 2012-10-18 22:54:55 · 427 阅读 · 0 评论 -
hdu 2602 Bone Collector
题目描述:Bone CollectorTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 14889 Accepted Submission(s): 5911Problem DescriptionMan原创 2012-10-19 18:29:52 · 330 阅读 · 0 评论 -
hdu 2955 Robberies
题目描述:RobberiesTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 5324 Accepted Submission(s): 2009Problem DescriptionThe aspir原创 2012-10-19 19:46:18 · 472 阅读 · 0 评论 -
hdu 1864 最大报销额
题目描述:最大报销额Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11009 Accepted Submission(s): 3010Problem Description现有一笔经费可以报销一定原创 2012-10-19 20:39:49 · 328 阅读 · 0 评论 -
hdu 3415 Max Sum of Max-K-sub-sequence
题目描述:Max Sum of Max-K-sub-sequenceTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 4208 Accepted Submission(s): 1503Problem De原创 2012-10-22 11:48:28 · 973 阅读 · 0 评论 -
HDU 1817 , POJ 1286
polya // hdu 1817 poj 1286// by utoppia// polya#includetypedef long long ll;ll pow(ll a,int n) { ll ret = 1ll; while(n--) ret *= a; return ret;}int gcd(int a,int b) { retur原创 2014-04-22 16:16:57 · 885 阅读 · 0 评论