- 博客(63)
- 收藏
- 关注
原创 杭电 1596 find the safest road (最短路)
http://acm.hdu.edu.cn/showproblem.php?pid=1596这道题目与杭电2544最短路的思想是一样的,只不过是把+改成了*,输入输出有些不一样而已。find the safest roadTime Limit: 10000/5000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Othe
2014-08-14 21:51:06 1000
原创 杭电 1166 敌兵布阵(线段树求和)
http://acm.hdu.edu.cn/showproblem.php?pid=1166敌兵布阵Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 43942 Accepted Submission(s): 18672
2014-08-12 21:44:11 817
原创 杭电 1754 I Hate It(线段树求最值)
http://acm.hdu.edu.cn/showproblem.php?pid=1754I Hate ItTime Limit: 9000/3000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 38601 Accepted Submission(s):
2014-08-12 19:44:40 871
原创 杭电 1698 Just a Hook(线段树区间修改)
http://acm.hdu.edu.cn/showproblem.php?pid=1698Just a HookTime Limit: 4000/2000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 17322 Accepted Submission(s)
2014-08-12 10:04:40 1041
原创 杭电 3270 The Diophantine Equation
http://acm.hdu.edu.cn/showproblem.php?pid=3270The Diophantine EquationTime Limit: 1000/500 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1146 Accepted Su
2014-08-11 21:30:28 1030
原创 杭电 2159 FATE(二维费用背包问题)
二维费用背包问题:对于每件物品,具有两种不同的费用;选择这件物品必须同时付出这两种代价;对于每种代价都有一个可付出的最大值(背包容量)。问怎样选择物品可以得到最大的价值。设这两种代价分别为代价1和代价2,第i件物品所需的两种代价分别为a[i]和b[i]。两种代价可付出的最大值(两种背包容量)分别为V和U。物品的
2014-08-08 15:16:20 908
原创 杭电 2546 饭卡(01背包)
http://acm.hdu.edu.cn/showproblem.php?pid=2546饭卡Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11285 Accepted Submission(s): 3880
2014-08-08 09:17:30 879
原创 杭电 1248 寒冰王座(完全背包)
http://acm.hdu.edu.cn/showproblem.php?pid=1248寒冰王座Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 10792 Accepted Submission(s): 5476
2014-08-07 21:25:53 913
原创 杭电 2191 悼念512汶川大地震遇难同胞——珍惜现在,感恩生活(多重背包)
http://acm.hdu.edu.cn/showproblem.php?pid=2191悼念512汶川大地震遇难同胞——珍惜现在,感恩生活Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 14531 Accepted
2014-08-07 16:11:24 1254
原创 杭电 1285 确定比赛名次(拓扑排序)
http://acm.hdu.edu.cn/showproblem.php?pid=1285确定比赛名次Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 11664 Accepted Submission
2014-08-07 09:57:30 851
原创 杭电 1025 Constructing Roads In JGShining's Kingdom(二分查找)
http://acm.hdu.edu.cn/showproblem.php?pid=1025Constructing Roads In JGShining's KingdomTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 1
2014-08-05 17:19:14 1147
原创 poj 1384 Piggy-Bank(完全背包)
http://poj.org/problem?id=1384Piggy-BankTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 7900Accepted: 3813DescriptionBefore ACM can do anything
2014-08-04 20:14:52 1089
原创 杭电 1231 最大连续子序列
http://acm.hdu.edu.cn/showproblem.php?pid=1231最大连续子序列Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 18622 Accepted Submission(s): 82
2014-08-04 19:23:02 915
原创 杭电 1069 Monkey and Banana
http://acm.hdu.edu.cn/showproblem.php?pid=1069Monkey and BananaTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 7397 Accepted Submissi
2014-08-04 16:28:13 1309 1
原创 杭电 1203 I NEED A OFFER!(01背包)
http://acm.hdu.edu.cn/showproblem.php?pid=1203I NEED A OFFER!Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 15759 Accepted Submissio
2014-08-03 20:46:30 934
原创 杭电 2124 Repair the Wall
http://acm.hdu.edu.cn/showproblem.php?pid=2124Repair the WallTime Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2076 Accepted Submission
2014-08-01 21:33:12 1738
原创 杭电2391 Filthy Rich &&杭电 2571 命运(动规)
由于这两个题目有递进关系所以把他们写在一个博客里面,希望对各位有帮助!http://acm.hdu.edu.cn/showproblem.php?pid=2391输入:13 41 10 8 80 0 1 80 27 0 4输出:Scenario #1:42题目大意:就是从一个矩阵的左上角走到它的右下角,矩阵的每一个元素都有一个非0值,只有三个方向可以走
2014-08-01 20:59:15 1076
原创 杭电 1800 Flying to the Mars(贪心)
http://acm.hdu.edu.cn/showproblem.php?pid=1800Flying to the MarsTime Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 10798 Accepted Submis
2014-08-01 12:28:48 1261
原创 01背包基础 (杭电2602)
01背包问题:有一个体积为V的背包,有n件物品,每件物品的体积,价值分别为w[i],p[i];要从n件物品中选些放入背包中,使背包里物品的总价值最大。动态方程:c[i][j]=max(c[i-1][j],c[i-1][j-w[i]]+p[i]).有关动态方程方面的代码:for (int i = 1; i <= n; i++) { for (int j = 1; j
2014-07-31 20:11:10 884
原创 杭电 1052 Tian Ji -- The Horse Racing(贪心)
http://acm.hdu.edu.cn/showproblem.php?pid=1052Tian Ji -- The Horse RacingTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 18058 Acce
2014-07-31 16:48:17 1045
原创 杭电 1176 免费馅饼
http://acm.hdu.edu.cn/showproblem.php?pid=1176免费馅饼Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 25157 Accepted Submission(s): 852
2014-07-30 19:34:22 1044
原创 杭电 1003 Max Sum
http://acm.hdu.edu.cn/showproblem.php?pid=1003Max SumTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 142781 Accepted Submission(s): 3
2014-07-29 20:31:37 796
原创 杭电 1029 Ignatius and the Princess IV
http://acm.hdu.edu.cn/showproblem.php?pid=1029Ignatius and the Princess IVTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32767 K (Java/Others)Total Submission(s): 16754 Accepte
2014-07-29 20:12:11 1027
原创 杭电 1087 Super Jumping! Jumping! Jumping!
http://acm.hdu.edu.cn/showproblem.php?pid=1087Super Jumping! Jumping! Jumping!Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 21884 A
2014-07-29 20:02:04 825
原创 杭电 1465 不容易系列之一(错排公式)
http://acm.hdu.edu.cn/showproblem.php?pid=1465不容易系列之一Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 14236 Accepted Submission(s): 59
2014-07-27 11:10:26 957
原创 杭电 1518 Square (深搜)(回溯)
http://acm.hdu.edu.cn/showproblem.php?pid=1518SquareTime Limit: 10000/5000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 8343 Accepted Submission(s): 270
2014-07-26 17:09:04 1364
原创 杭电 1242 Rescue(广搜)
http://acm.hdu.edu.cn/showproblem.php?pid=1242RescueTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 15597 Accepted Submission(s): 566
2014-07-26 17:03:56 966
原创 杭电 1548 A strange lift(广搜)
http://acm.hdu.edu.cn/showproblem.php?pid=1548A strange liftTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 11341 Accepted Submission
2014-07-25 16:49:57 868
原创 杭电 1372 Knight Moves(广搜模板题)
http://acm.hdu.edu.cn/showproblem.php?pid=1372Knight MovesTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 6439 Accepted Submission(s)
2014-07-25 15:47:49 1198
原创 杭电 2544 最短路
http://acm.hdu.edu.cn/showproblem.php?pid=2544最短路Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 30857 Accepted Submission(s): 13293
2014-07-24 16:25:51 852
原创 杭电 1280 前m大的数
http://acm.hdu.edu.cn/showproblem.php?pid=1280前m大的数Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 10382 Accepted Submission(s): 3614
2014-07-23 22:14:26 984
转载 vector的用法!
vector的用法1.vector 的数据的存入和输出:#include#include#include using namespace std;void main(){ int i = 0; vector v; for( i = 0; i { v.
2014-07-22 21:45:16 910
原创 杭电 2015 偶数求和
http://acm.hdu.edu.cn/showproblem.php?pid=2015偶数求和Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 45044 Accepted Submission(s):
2014-07-22 21:16:00 1330
原创 周期串 字符串的最小正周期
输入一个长度不超过80的字符串,输出它的最小周期。样例输入:HoHoHo样例输出:2代码:#include#includeint main(){ char word[100]; scanf("%s",word); int len=strlen(word); for(int i=1;i<=len;i++) if(len%i==0) { int ok=1;
2014-07-22 20:04:24 1209
原创 杭电 1108 最小公倍数
http://acm.hdu.edu.cn/showproblem.php?pid=1108最小公倍数Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 32700 Accepted Submission(s): 1823
2014-07-21 21:20:43 1508
原创 杭电 2034 人见人爱A-B
http://acm.hdu.edu.cn/showproblem.php?pid=2034人见人爱A-BTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 43093 Accepted Submission(s): 12
2014-07-19 19:55:27 1106
原创 杭电 2187 (贪心题)悼念512汶川大地震遇难同胞——老人是真饿了
http://acm.hdu.edu.cn/showproblem.php?pid=2187悼念512汶川大地震遇难同胞——老人是真饿了Time Limit: 1000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 7286 Accepted Sub
2014-07-19 11:29:49 1107
原创 杭电 3177 Crixalis's Equipment
http://acm.hdu.edu.cn/showproblem.php?pid=3177Crixalis's EquipmentTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 2562 Accepted S
2014-07-19 10:02:24 957
原创 杭电 1150 moving tables
http://acm.hdu.edu.cn/showproblem.php?pid=1050Moving TablesTime Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 18850 Accepted Submission(
2014-07-19 09:20:42 1437
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人