水题
yfxie666
这个作者很懒,什么都没留下…
展开
-
2018 ACM-ICPC Syrian Collegiate Programming Contest
Problem H: Bugged System思路来源**(https://blog.csdn.net/Mitsuha_/article/details/84455292)**Mr. Light is visiting a city with a “smart” metro system. Or so it seems …There are exactly n stations in a ...原创 2019-07-29 22:36:51 · 313 阅读 · 0 评论 -
HDU 1874 畅通工程续
题目某省自从实行了很多年的畅通工程计划后,终于修建了很多路。不过路多了也不好,每次要从一个城镇到另一个城镇时,都有许多种道路方案可以选择,而某些方案要比另一些方案行走的距离要短很多。这让行人很困扰。现在,已知起点和终点,请你计算出要从起点到终点,最短需要行走多少距离。Input本题目包含多组数据,请处理到文件结束。 每组数据第一行包含两个正整数N和M(0<N<200,0<...原创 2019-07-30 17:27:09 · 64 阅读 · 0 评论 -
HDU 3790 最短路径问题
题目给你n个点,m条无向边,每条边都有长度d和花费p,给你起点s终点t,要求输出起点到终点的最短距离及其花费,如果最短距离有多条路线,则输出花费最少的。Input输入n,m,点的编号是1~n,然后是m行,每行4个数 a,b,d,p,表示a和b之间有一条边,且其长度为d,花费为p。最后一行是两个数 s,t;起点s,终点。n和m为0时输入结束。 (1<n<=1000, 0<m&...原创 2019-07-30 17:41:59 · 115 阅读 · 0 评论 -
Training Contest 5 H - H to O
题目C6H12O6+6O2→6CO2+6H2OProfessor Cesium has created a new process to transform some chemical product into another type of chemical with some residues. The process is simple: he just needs to input a...原创 2019-08-08 11:34:08 · 474 阅读 · 0 评论 -
Training Contest 4 D - Dreamer
Bash just woke up from his sweetest dream ever. In his dream, he became the best Pokenom trainer — like no one ever was. It was on the date …Unfortunately, Bash forgot the exact date. He only remembe...原创 2019-08-06 21:57:53 · 178 阅读 · 0 评论 -
Training Contest 4 J - Joyless Game
Playing games is the best way to improve flexibility, critical thinking and strategy.To become the best Pokenom player, Bash is playing some games with his Pokenom Chikapu.Bash writes down a string ...原创 2019-08-06 22:05:04 · 218 阅读 · 0 评论 -
2018 ICPC Asia Singapore Regional Non-Prime Factors
题目In many programming competitions, we are asked to find (or count the number of) Prime Factors of an integer i. This is boring. This time, let’s count the number of Non-Prime Factors of an integer i...原创 2019-08-10 11:21:53 · 649 阅读 · 0 评论 -
HDU 2612 Find a way
Problem DescriptionPass a year learning in Hangzhou, yifenfei arrival hometown Ningbo at finally. Leave Ningbo one year, yifenfei have many people to meet. Especially a good friend Merceki.Yifenfei’...原创 2019-08-17 14:57:05 · 67 阅读 · 0 评论 -
HDU 2553 N皇后问题
Problem Description在N*N的方格棋盘放置了N个皇后,使得它们不相互攻击(即任意2个皇后不允许处在同一排,同一列,也不允许处在与棋盘边框成45角的斜线上。你的任务是,对于给定的N,求出有多少种合法的放置方法。Input共有若干行,每行一个正整数N≤10,表示棋盘和皇后的数量;如果N=0,表示结束。Output共有若干行,每行一个正整数,表示对应输入行的皇后的不同放置数...原创 2019-08-18 15:38:55 · 94 阅读 · 0 评论