摘要: B - 报数游戏Time Limit:1000MS Memory Limit:65535KB 64bit IO Format:%I64d & %I64uSubmitStatusDescriptionn个人站成一行玩一个报数游戏。所有人从左到右编号为1到n。游戏开始时,最左边的人报1,... 阅读全文
posted @ 2014-08-16 00:46 sola94 阅读(1066) 评论(0) 推荐(0) 编辑
摘要: E - 盒子游戏有两个相同的盒子,其中一个装了n个球,另一个装了一个球。Alice和Bob发明了一个游戏,规则如下:Alice和Bob轮流操作,Alice先操作每次操作时,游戏者先看看哪个盒子里的球的数目比较少,然后清空这个盒子(盒子里的球直接扔掉),然后把另一个盒子里的球拿一些到这个盒子中,使得两... 阅读全文
posted @ 2014-08-16 00:45 sola94 阅读(478) 评论(0) 推荐(0) 编辑
摘要: A - 一二三Time Limit:1000MS Memory Limit:65535KB 64bit IO Format:%I64d & %I64uSubmitStatusDescription你弟弟刚刚学会写英语的一(one)、二(two)和三(three)。他在纸上写了好些一二... 阅读全文
posted @ 2014-08-16 00:43 sola94 阅读(367) 评论(0) 推荐(0) 编辑
摘要: 题意: 拉登有面值 1 2 5 的钱币 分别 n1 n2 n5 个 求出最大能连续组合到多大 思路: 想来想去都有bug 最后简单粗暴的一个一个来处理了#include#include#include#include#include#include#include#define mem... 阅读全文
posted @ 2014-08-16 00:41 sola94 阅读(119) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=1599floyd真的是水很深啊 各种神奇ans=min(ans,g[i][k]+g[k][j]+d[i][j]);#include#include#include#include#include#include#i... 阅读全文
posted @ 2014-08-15 00:25 sola94 阅读(116) 评论(0) 推荐(0) 编辑
摘要: DescriptionAssume the coasting is an infinite straight line.Land is in one side of coasting, sea in the other.Each small island is a point locating in... 阅读全文
posted @ 2014-08-15 00:21 sola94 阅读(127) 评论(0) 推荐(0) 编辑
摘要: DescriptionBackgroundOur knight lives on a chessboard that has a smaller area than a regular 8 * 8 board,but it is still rectangular.Can you help this... 阅读全文
posted @ 2014-08-14 01:29 sola94 阅读(157) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=2544最简单的最短路了吧 改天试试优化版本的#include#include#include#include#include#include#include#define mem(a,b) memset(a,b,s... 阅读全文
posted @ 2014-08-14 01:21 sola94 阅读(96) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=2015水题啦 直接贴代码#include#include#include#include#include#include#include#define mem(a,b) memset(a,b,sizeof(a))#... 阅读全文
posted @ 2014-08-14 01:19 sola94 阅读(135) 评论(0) 推荐(0) 编辑
摘要: http://acm.hdu.edu.cn/showproblem.php?pid=2063思路:先给一个女生1找个对应的男生再到下个女生2 如果这个女生找到的男生已经有对应的女生1再找女生1的增广路到最后得到最大匹配#include#include#include#include#include#... 阅读全文
posted @ 2014-08-14 01:12 sola94 阅读(225) 评论(0) 推荐(0) 编辑