Description
Farmer John wants the cows to prepare for the county jumping competition, so Bessie and the gang are practicing jumping over hurdles. They are getting tired, though, so they want to be ...
分类:
其他好文 时间:
2014-06-08 15:55:10
阅读次数:
199
Catch That Cow
Time Limit: 2000MS
Memory Limit: 65536K
Total Submissions: 44070
Accepted: 13764
Description
Farmer John has been informed of the location of a fugitiv...
分类:
其他好文 时间:
2014-06-08 15:44:43
阅读次数:
238
Hash 索引结构的特殊性,其检索效率非常高,索引的检索可以一次定位,不像B-Tree
索引需要从根节点到枝节点,最后才能访问到页节点这样多次的IO访问,所以 Hash 索引的查询效率要远高于 B-Tree 索引。可能很多人又有疑问了,既然
Hash 索引的效率要比 B-Tree 高很多,为什么大家...
分类:
数据库 时间:
2014-06-06 21:42:24
阅读次数:
344
Catch That CowDescriptionFarmer John has been
informed of the location of a fugitive cow and wants to catch her immediately.
He starts at a point N (0...
分类:
其他好文 时间:
2014-06-05 19:54:29
阅读次数:
298
Catch That Cow
Time Limit: 2000MS
Memory Limit: 65536K
Total Submissions: 43851
Accepted: 13674
Description
Farmer John has been informed of the location of a fugitiv...
分类:
其他好文 时间:
2014-06-05 07:45:38
阅读次数:
220
裸dijkstra
思路:以x为源点,求到其他点的最短路,之后把邻接矩阵转置,再求一次x源
点的最短路,这样就一次是来的,一次是走的,相加迭代最大值即可
代码:
/*
poj 3268
8108K 47MS
*/
#include
#include
#define MAXN 1005
#define MAX_INT 2147483647
using namespace s...
分类:
其他好文 时间:
2014-06-04 23:32:57
阅读次数:
303
http://poj.org/problem?id=3270这道题就是给你一个无序序列转换成有序序列需要花费的代价最小,交换a和b代价为a+b; 1
#include 2 #include 3 #include 4 #define maxn 20000 5 using namespace st...
分类:
其他好文 时间:
2014-06-03 13:14:32
阅读次数:
272
Farmer John has been informed of the location of a fugitive cow and wants to catch her immediately. He starts at a point N (0 ≤ N ≤ 100,000) on a number line and the cow is at a point K (0 ≤ K ≤ 100,0...
分类:
其他好文 时间:
2014-06-03 05:30:23
阅读次数:
394
btree和hashHash
索引结构的特殊性,其检索效率非常高,索引的检索可以一次定位,不像B-Tree 索引需要从根节点到枝节点,最后才能访问到页节点这样多次的IO访问,所以 Hash
索引的查询效率要远高于 B-Tree 索引。可能很多人又有疑问了,既然 Hash 索引的效率要比 B-Tree...
分类:
数据库 时间:
2014-05-31 21:02:50
阅读次数:
354
题目大意:
一个农主寻找牛。给出农主的位置n和牛的位置k。农主可以通过n-1或者n+1或者n*2的步伐找牛,问至少多少步才能找到自己的牛。解题思路:
简单的BFS。把农主的每一种可能的步伐通过BFS存到栈中,然后看最少多少步到达K坐标。代码: 1 #include 2 #include 3 ...
分类:
其他好文 时间:
2014-05-31 15:27:27
阅读次数:
252