http://poj.org/problem?id=2186DescriptionEvery cow's dream is to become the most popular cow in the herd. In a herd of N (1 #include#include#include#i...
分类:
移动开发 时间:
2015-08-21 15:10:31
阅读次数:
165
题目链接:http://poj.org/problem?id=2186求有多少个点满足其他n-1个点都能到达这个点,是单向图;所以我们可以把图进行缩点,之后求出度为0的那个点内包含的点的个数就是求得答案;如果出度为0的不止一个,那么答案为0;#include#include#include#incl...
分类:
移动开发 时间:
2015-08-21 13:24:59
阅读次数:
145
现在需要远程复制源码包使用scp命令:[root@localhostDownloads]#scp
nginx-1.6.2.tar.gz172.25.16.2:root@172.25.16.2‘spassword:bash:
scp:commandnotfound//提示错误lost
connection//解决方法:[root@localhostDownloads]#which
scp/bin/scp[root@localhostDownloads]#rpm-..
分类:
其他好文 时间:
2015-08-21 00:25:08
阅读次数:
129
A. POJ 2387 Til the Cows Come Home模板题.#include#include#include#include#include#include#include#include#include#includeusing namespace std;const int IN...
分类:
其他好文 时间:
2015-08-20 01:20:00
阅读次数:
166
Popular Cows
Time Limit: 2000MS
Memory Limit: 65536K
Total Submissions: 27198
Accepted: 10963
Description
Every cow's dream is to become the most popular cow in the...
分类:
其他好文 时间:
2015-08-19 20:47:09
阅读次数:
145
BZOJ 1703 [Usaco2007 Mar]Ranking the Cows 奶牛排名 bitset优化...
分类:
其他好文 时间:
2015-08-18 22:47:11
阅读次数:
441
题目:click here题意:给定一个无向图,有T条边,N个顶点,问从1到n的最短路。下面给出3种dijkstra算法分别用邻接矩阵,邻接表,和堆优化后的代码。邻接表堆优化:O(ElogV) 1 #include 2 #include 3 #include 4 #include 5 #...
分类:
其他好文 时间:
2015-08-18 21:00:43
阅读次数:
107
Description
Bessie noted that although humans have many universities they can attend, cows have none. To remedy this problem, she and her fellow cows formed a new university called The University...
分类:
其他好文 时间:
2015-08-18 16:24:17
阅读次数:
123
题目链接:Lost's revenge
解析:n个模式串,一个目标串。问目标串通过任意次交换字符最多能包含的模式串个数。(允许重叠)
字符最长是40
只需要记录ACGT出现的次数。
如果使用5维数组,显然超内存了。
假设ACGT的总数分别为num[0],num[1],num[2],num[3]
那么对于ACGT的数量分别为ABCD的状态可以记录为: (网上大神讲的...
分类:
其他好文 时间:
2015-08-18 12:04:35
阅读次数:
145
题目链接
http://poj.org/problem?id=2431
Expedition
Time Limit: 1000MS
Memory Limit: 65536K
Total Submissions: 9243
Accepted: 2700
Description
A group of cows grab...
分类:
其他好文 时间:
2015-08-17 17:25:37
阅读次数:
130