码迷,mamicode.com
首页 >  
搜索关键字:poj 3348 cows    ( 21218个结果
POJ 3069 Saruman's Army
Saruman's Army Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 3519   Accepted: 1787 Description Saruman the White must lead his army along a straight path...
分类:其他好文   时间:2014-05-22 10:09:49    阅读次数:271
poj 2411 Mondriaan's Dream(转态压缩)
题目链接:poj 2411 Mondriaan's Dream 题目大意:用1?2的木块填满n?m的矩阵有多少种方法。 解题思路:插头dp裸题。uva11270 #include #include typedef long long ll; const int N = 13; int n, m; ll set, dp[N+5][(15]; void solve (int d,...
分类:其他好文   时间:2014-05-22 08:06:07    阅读次数:177
POJ 3253 Fence Repair
Fence Repair Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 24153   Accepted: 7703 Description Farmer John wants to repair a small length of the fence aroun...
分类:其他好文   时间:2014-05-22 07:55:44    阅读次数:255
POJ 2431 Expedition
ExpeditionTime Limit:  1000MSMemory Limit:  65536KDescriptionA group of cows grabbed a truck and ventured on an expedition deep into the jungle. Being rather poor drivers, the cows unfortunately manag...
分类:其他好文   时间:2014-05-22 06:16:01    阅读次数:423
poj 1141 Brackets Sequence(区间DP)
题目:http://poj.org/problem?id=1141转载:http://blog.csdn.net/lijiecsu/article/details/7589877定义合法的括号序列如下:1 空序列是一个合法的序列2 如果S是合法的序列,则(S)和[S]也是合法的序列3 如果A和B是合...
分类:其他好文   时间:2014-05-22 02:52:11    阅读次数:256
POJ 2192 Zipper
大体题意: 先输入试验次数num,再输入三个字符串A,B,C,判断C可否由A,B按照某种次序组成。如下图。 #include #include using namespace std; #define MAX_SIZE 205 char A[MAX_SIZE]; char B[MAX_SIZE]; char C[2 * MAX_SIZE]; bool...
分类:其他好文   时间:2014-05-21 16:05:09    阅读次数:209
poj 3735 Training little cats(矩阵快速幂)
Description Facer's pet cat just gave birth to a brood of little cats. Having considered the health of those lovely cats, Facer decides to make the cats to do some exercises. Facer has well designe...
分类:其他好文   时间:2014-05-21 10:36:57    阅读次数:297
POJ 2142 The Balance
SOL : 扩展的欧几里德,  ax+by==c   x=x0+b/d*t; y=y0-a/d*t; 求|x|+|Y|的最小值 可以发现: |x0+b/d*t| 单调递增      |y0-a/d*t| 单调递减  因为 a>b,所以就是说函数是凹的,先减小后增大。 显然  当y0-a/d*t==0的时候  |x|+|Y| 最小值就在那附近。 枚举几个值就能找到。 #in...
分类:其他好文   时间:2014-05-21 09:25:41    阅读次数:290
Poj 1112 Team Them Up!
题意:现在有一群人,告诉你每个人都认识哪些人,让你将这一群人分成两组,其中每一组中的每个人都相互认识,并且使得两组中的人数尽量相近。问你是否能分成这样两组,如果不能输出No Solution ,否则输出人数最相近的方案。 注意你认识我不代表我认识你,组中的每一个人都必须是相互认识的。 首先建立由人和...
分类:其他好文   时间:2014-05-21 05:04:15    阅读次数:306
poj 1330 Nearest Common Ancestors
DescriptionA rooted tree is a well-known data structure in computer science and engineering. An example is shown below:In the figure, each node is lab...
分类:其他好文   时间:2014-05-21 03:23:51    阅读次数:296
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!