随笔分类 - acm 解题报告
摘要:快速链接:http://poj.org/problem?id=2063CSUST 2012年暑假8月组队后第八次个人赛:http://acm.hust.edu.cn:8080/judge/contest/view.action?cid=11473#problem/DInvestmentTime Limit:1000MSMemory Limit:30000KTotal Submissions:5370Accepted:1848DescriptionJohn never knew he had a grand-uncle, until he received the notary's le
阅读全文
摘要:题目链接: http://poj.org/problem?id=31252012年8月7日,暑假组队后个人训练赛第一场Printer QueueTime Limit:1000MSMemory Limit:65536KTotal Submissions:3082Accepted:1655DescriptionThe only printer in the computer science students' union is experiencing an extremely heavy workload. Sometimes there are a hundred jobs in th
阅读全文
摘要:题目链接:http://poj.org/problem?id=15792012年暑假组队后第一场个人训练赛FunctionRunFunTimeLimit:1000MSMemoryLimit:10000KTotalSubmissions:13148Accepted:6836DescriptionWeallloverecursion!Don'twe?Considerathree-parameterrecursivefunctionw(a,b,c):ifa<=0orb<=0orc<=0,thenw(a,b,c)returns:1ifa>20orb>20orc&g
阅读全文
摘要:题目链接:http://poj.org/problem?id=1573 http://acm.hdu.edu.cn/showproblem.php?pid=1035Robot MotionTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 3893Accepted Submission(s): 1817Problem DescriptionA robot has been programmed to follow the instr...
阅读全文
摘要:根据大数相加,写出的简单的大数相乘的模板,有待改进中~~~~~~#include<stdio.h>#include<string.h>const int N = 100;int main(){ int i,j,k; int d1,d2; int a[N]={0},b[N]={0},sum[2*N]={0}; char c[N];// memset(c,'0',sizeof(c));// memset(a,0,sizeof(a));// memset(b,0,sizeof(b));// memset(sum,0,sizeof(sum));// ...
阅读全文
摘要:原作者已经找不到了,但是我是从CSUST的博客栏中看到的,一个很好的模板。我看到的文章来源(不是原出处):http://blog.csdn.net/csust_acm/article/details/7268029//大数相加#include <stdio.h>#include<string.h>int main(){ int i,d,j,d1; char a[100];int b[101]={0};int c[100]={0}; // memset(b,0,sizeof(b)); // memset(c,0,sizeof(c)); scanf("%s&quo
阅读全文
摘要:题目链接: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): 9069Accepted Submission(s): 2579Problem DescriptionJGShining's kingdom consists of 2n(n is no more t
阅读全文
摘要:题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1114Piggy-BankTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 5450Accepted Submission(s): 2714Problem DescriptionBefore ACM can do anything, a budget must be prepared and the necessary financial suppor
阅读全文
摘要:题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1058Humble NumbersTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 9933Accepted Submission(s): 4291Problem DescriptionA number whose only prime factors are 2,3,5 or 7 is called a humble number. The sequ
阅读全文
摘要:题目链接: http://acm.hdu.edu.cn/showproblem.php?pid=2084数塔Time Limit: 1000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 11282Accepted Submission(s): 6761Problem Description在讲述DP算法的时候,一个经典的例子就是数塔问题,它是这样描述的:有如下所示的数塔,要求从顶层走到底层,若每一步只能走到相邻的结点,则经过的结点的数字之和最大是多少?已经告诉你了,这是个D
阅读全文
摘要:题目链接: 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): 14396Accepted Submission(s): 4763Problem Description都说天上不会掉馅饼,但有一天gameboy正走在回家的小径上,忽然天上掉下大把大把的馅饼。说来gameboy的人品实在是太好了,这馅饼别处都不掉,就掉落在他身旁的10米范围内。馅饼如果
阅读全文
摘要:题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=2602 Bone CollectorTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 13839Accepted Submission(s): 5454Problem DescriptionMany years ago , in Teddy’s hometown there was a man who was ca...
阅读全文
摘要:题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1506Largest Rectangle in a HistogramTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 5475Accepted Submission(s): 1570Problem DescriptionA histogram is a polygon composed of a sequence of rectangles alig
阅读全文
摘要:题目链接: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): 11885Accepted Submission(s): 5005Problem Description给定K个整数的序列{ N1, N2, ..., NK },其任意连续子序列可表示为{ Ni, Ni+1, ...,Nj },其中 1 <= i <= j <= K
阅读全文
摘要:POJ 1573 && hdu 1035(简单模拟)感谢kb神题目链接:http://poj.org/problem?id=1573 http://acm.hdu.edu.cn/showproblem.php?pid=1035Robot MotionTime Limit: 1000MSMemory Limit: 10000KTotal Submissions: 7893Accepted: 3813DescriptionA robot has been programmed to follow the instructions in its path. Instructions
阅读全文
摘要:水鸟第一篇解题报告,大牛们直接忽略即可题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1060LeftmostDigitProblemDescriptionGivenapositiveintegerN,youshouldoutputtheleftmostdigitofN^N.InputTheinputcontainsseveraltestcases.ThefirstlineoftheinputisasingleintegerTwhichisthenumberoftestcases.Ttestcasesfollow.Eachtestcaseconta
阅读全文
摘要:水鸟第一篇解题报告,大牛们直接忽略即可题目链接:http://acm.hdu.edu.cn/showproblem.php?pid=1060LeftmostDigitProblemDescriptionGivenapositiveintegerN,youshouldoutputtheleftmostdigitofN^N.InputTheinputcontainsseveraltestcases.ThefirstlineoftheinputisasingleintegerTwhichisthenumberoftestcases.Ttestcasesfollow.Eachtestcaseconta
阅读全文

浙公网安备 33010602011771号