算法竞赛入门经典(第二版)
文章平均质量分 78
AC_Dreameng
行有余力,则来刷题!
展开
-
HDU 1241/UVa572 Oil Deposits(DFS&BFS)
Oil DepositsTime Limit : 2000/1000ms (Java/Other) Memory Limit : 65536/32768K (Java/Other)Total Submission(s) : 2 Accepted Submission(s) : 2Problem DescriptionThe GeoSurvComp geolo原创 2016-03-22 18:14:35 · 1661 阅读 · 0 评论 -
UVA 1225 Digit Counting(统计数位出现的次数)
Digit CountingTime Limit: 3000MS Memory Limit: Unknown 64bit IO Format: %lld & %lluSubmitStatusDescriptionTrung is bored with his mathematics homeworks. He ta原创 2016-05-20 20:05:54 · 7418 阅读 · 0 评论 -
UVA 10474 Where is the Marble? (STL最简单运用)
Where is the Marble? DescriptionRaju and Meena love to play with Marbles. They have got a lot of marbles with numbers written on them. At the beginning, Raju would place the marbles one after a原创 2016-05-16 22:59:18 · 5315 阅读 · 3 评论 -
UVa 227 Puzzle (紫书上的题,模拟)
Puzzle A children's puzzle that was popular 30 years ago consisted of a 5x5 frame which contained 24 small squares of equal size. A unique letter of the alphabet was printed on each small原创 2016-05-26 23:45:58 · 4628 阅读 · 0 评论 -
UVA 455 Periodic Strings (最短周期串长度)
Periodic Strings A character string is said to have period k if it can be formed by concatenating one or more repetitions of another string of length k. For example, the string "abcabc原创 2016-05-25 23:08:25 · 3551 阅读 · 0 评论 -
Uva1585 Score (简单统计)
ScoreDescriptionThere is an objective test result such as ``OOXXOXXOOO". An `O' means a correct answer of a problem and an `X' means a wrong answer. The score of each problem of this test is c原创 2016-03-13 20:25:23 · 1421 阅读 · 0 评论 -
UVa1225Digit Counting(计算1-n的整数0-9各出现了多少次,神级代码...)
UVA - 1225Digit CountingTime Limit: 3000MS Memory Limit: Unknown 64bit IO Format: %lld & %lluSubmitStatus DescriptionTrung is bored with his mathema原创 2016-03-13 21:07:15 · 6820 阅读 · 5 评论 -
UVa 1586 Molar mass (计算分子量,不含扩号)
Molar massDescriptionAn organic compound is any member of a large class of chemical compounds whose molecules contain carbon. Themolarmass of an organic compound is the mass of one m原创 2016-03-13 20:38:03 · 2427 阅读 · 0 评论 -
习题2-5 分数化小数(decimal)
分数化小数输入正整数a,b,c,输出a/b的小数形式,精确到小数点后c位.a,b输入包含多组数据,结束标记为a=b=c=0样例输入:1 6 40 0 0样例输出:Case 1: 0.1667#include#includeint main(){ int a, b, c; int cas=0; while(scanf("%原创 2016-03-12 23:20:32 · 3637 阅读 · 0 评论 -
程序2-11 数据统计(fopen版)
统计最值及平均值。如果比赛要求用文件输入输出,禁止用重定向的方式,就用下面这个代码。#include#define INF 1000000000int main(){ FILE *fin,*fout; fin=fopen("data.in","rb"); fout=fopen("data.out","wb"); in原创 2016-02-27 12:52:38 · 760 阅读 · 0 评论 -
程序2-10 数据统计 (重定向版)
统计数据的最值,及平均值。#define LOCAl#include#define INF 1000000000int main(){#ifdef LOCAL freopen("data.in","r",stdin); freopen("data.out","w",stdout);#endif int x,n=0,min=INF,max=-INF,s=0;原创 2016-02-27 12:15:18 · 777 阅读 · 0 评论 -
刘汝佳紫书白书题集
Official resources for the book series >丛书《算法艺术与信息学竞赛》官方资料,包括代码、测试数据、勘误等官方资料《算法竞赛入门经典》相关资料: BeginningAlgorithmContests《算法竞赛入门经典——训练指南》相关资料: TrainingGuide《算法竞赛入门经典(第二版)》相关资料: Beginn原创 2016-09-20 19:55:13 · 6466 阅读 · 0 评论