题意: 有很多羊,每只羊有一个幽默度和智商,要选出一些羊,智商加幽默度总和最大,其中智商总和和幽默度总和都不能是负数。 样例输入: 5 -5 7 8 -6 6 -3 2 1 -8 -5 样例输出: 8 分析: 这很像一个01背包题,但是有两个价值,却没有重量 我们就把其中一个看成重量,另一个看成价值 ...
分类:
其他好文 时间:
2018-06-24 00:53:18
阅读次数:
157
题目: Popular Cows Time Limit: 2000MS Memory Limit: 65536K Total Submissions: 38415 Accepted: 15658 Description Every cow's dream is to become the most ...
分类:
其他好文 时间:
2018-06-24 00:43:36
阅读次数:
167
kvm快照 # virsh shutdown kvm1 # qemu-img info /var/lib/libvirt/images/kvm1.img raw格式是不支持snapshot功能,所以我们需要转换成象qcow2这种支持snapshot功能的格式(rhel7,cenots7已经默认是qc ...
分类:
其他好文 时间:
2018-06-19 22:44:46
阅读次数:
203
老唐最近迷上了飞盘,约翰想和他一起玩,于是打算从他家的N头奶牛中选出一支队伍。 每只奶牛的能力为整数,第i头奶牛的能力为R i 。飞盘队的队员数量不能少于 1、大于N。 一支队伍的总能力就是所有队员能力的总和。 约翰比较迷信,他的幸运数字是F,所以他要求队伍的总能力必须是F的倍数。请帮他 算一下,符 ...
分类:
其他好文 时间:
2018-06-18 21:49:27
阅读次数:
163
描述 Keeping track of all the cows can be a tricky task so Farmer John has installed a system to automate it. He has installed on each cow an electronic ...
分类:
其他好文 时间:
2018-06-15 22:43:19
阅读次数:
213
Many years ago , in Teddy’s hometown there was a man who was called “Bone Collector”. This man like to collect varies of bones , such as dog’s , cow’s ...
分类:
其他好文 时间:
2018-06-15 22:37:54
阅读次数:
136
"Fat and docile, big and dumb, they look so stupid, they aren't much fun..." - Cows with Guns by Dana Lyons The cows want to prove to the public that ...
分类:
其他好文 时间:
2018-06-15 22:35:09
阅读次数:
159
题目描述 FJ is about to take his N (1 ≤ N ≤ 30,000) cows to the annual"Farmer of the Year" competition. In this contest every farmer arranges his cows in ...
分类:
其他好文 时间:
2018-06-12 18:34:04
阅读次数:
157
给定两个整数n和k,通过 n+1或n-1 或n*2 这3种操作,使得n==k 输出最少的操作次数 ...
分类:
其他好文 时间:
2018-06-12 17:43:09
阅读次数:
104
题目描述 Farmer John has noticed that the quality of milk given by his cows varies from day to day. On further investigation, he discovered that although ...
分类:
其他好文 时间:
2018-06-11 18:59:32
阅读次数:
130