第一反应又是贪心。。。但不知道第二步开始怎么贪,又看到最多有15种饲料,枚举不会超时,而且可以状态压缩。
ans从17位开始保存选取饲料的种数,前16位保存养料的取舍情况。...
分类:
其他好文 时间:
2015-08-31 19:49:48
阅读次数:
138
由于0是最小的数,所以0必须有,然后DFS搜索即可,由于是从小到大枚举,所以找到的第一个就是题目所求答案。...
分类:
其他好文 时间:
2015-08-31 19:43:05
阅读次数:
118
January (Jan.) 一月;
February (Feb.) 二月;
March (Mar.) 三月;
April (Apr.) 四月;
May (may.)五月;
June(Jun.)六月;
July(Jul.)七月;
August(Aug.)八月;
September(Sept.)九月;
October(Oct.)十月;
November(Nov.)十一月;
De...
分类:
其他好文 时间:
2015-08-30 21:21:45
阅读次数:
119
Gold minerTime Limit: 4000/2000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 1889Accepted Submission(s): 740Time Limi...
分类:
其他好文 时间:
2015-08-30 21:02:15
阅读次数:
336
数据很小,直接将所有数存入数组,然后排序即可。
注意:只有最简分数才放入数组,因为如果它不是最简分数,则它化简后一定能在数组中找到...
分类:
编程语言 时间:
2015-08-30 19:41:08
阅读次数:
212
由于数据很小,所以求出房间数目后直接枚举每一个点的北墙和东墙即可。
样例样例还是很全面的,刚开始没考虑墙的两边是一个房间,样例都过不了。。。...
分类:
其他好文 时间:
2015-08-30 17:30:00
阅读次数:
172
Name That NumberAmong the large Wisconsin cattle ranchers, it is customary to brand cows with serial numbers to please the Accounting Department. The ...
分类:
其他好文 时间:
2015-08-29 15:15:18
阅读次数:
204
Best Cow Line, Gold
Time Limit: 5000MS
Memory Limit: 65536K
Total Submissions: 5063
Accepted: 1806
Description
FJ is about to take his N (1 ≤ N ≤ 30,000) cows to th...
分类:
编程语言 时间:
2015-08-29 12:43:45
阅读次数:
227
数据集文件:
customers:
1,Stephanie leung,555-555-555
2,Edward Kim,123-456-7890
3,Jose Madriz,281-330-8004
4,David Stork,408-555-0000
orders:
3,A,12.95,02-Jun-2008
1,B,88.25,20-May-2008
2,C,32.00,30-Nov...
分类:
其他好文 时间:
2015-08-29 09:54:52
阅读次数:
203
TransformationsA square pattern of size N x N (1 #include using namespace std;const int maxn=11;int N;char before1[maxn][maxn],after1[maxn][maxn];bool...
分类:
其他好文 时间:
2015-08-29 09:42:10
阅读次数:
157