摘要:
Minimum Transport CostTime Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 4487Accepted Submission(s): ... 阅读全文
posted @ 2012-08-21 20:22
加拿大小哥哥
阅读(356)
评论(0)
推荐(1)
摘要:
I Wanna Go HomeTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 2488Accepted: 1041DescriptionThe country is facing a terrible civil war----cit... 阅读全文
posted @ 2012-08-21 18:16
加拿大小哥哥
阅读(219)
评论(0)
推荐(1)
摘要:
View Code 1 /* 2 前缀子串能否有某个周期串重复k次,输出子串长度和最大的k,也就是最小周期情况下的k。 3 也就是说求前缀子串的最大循环节 4 方法: 遍历前缀子串,若周期存在则输出,关键在于如何求最小周期 5 */ 6 #include <iostream> 7 #include <cstdlib> 8 #include <cstring> 9 #include <string>10 using namespace std;11 int next[1000010];12 string s;13 void get()14 {15 阅读全文
posted @ 2012-08-21 15:49
加拿大小哥哥
阅读(541)
评论(0)
推荐(0)
摘要:
1 //仍然bfs+判重 2 #include <iostream> 3 #include <stdio.h> 4 #include <cstring> 5 #include <queue> 6 using namespace std; 7 typedef struct Node 8 { 9 int x,y; 10 int step; 11 }Node; 12 Node ch[1000]; 13 bool vis[10][10]; 14 int bfs(int r1,int c1,int r2,int c2) 15 { 16 int i,j,k, 阅读全文
posted @ 2012-08-21 14:26
加拿大小哥哥
阅读(456)
评论(0)
推荐(1)
摘要:
搬寝室Time Limit: 2000/1000 MS (Java/Others)Memory Limit: 65536/32768 K (Java/Others)Total Submission(s): 9687Accepted Submission(s): 3257Problem Description搬寝室是很累的,xhd深有体会.时间追述2006年7月9号,那天xhd迫于无奈要从27号楼搬到3号楼,因为10号要封楼了.看着寝室里的n件物品,xhd开始发呆,因为n是一个小于2000的整数,实在是太多了,于是xhd决定随便搬2*k件过去就行了.但还是会很累,因为2*k也不小是一个不大于n的 阅读全文
posted @ 2012-08-21 11:18
加拿大小哥哥
阅读(194)
评论(0)
推荐(1)
摘要:
1437: 校长杯Time Limit: 1500 ms Memory Limit: 32000 kB Judge type: Multi-cases Special JudgeTotal Submit : 110(53 users)Accepted Submit : 67(47 users)Pa... 阅读全文
posted @ 2012-08-21 08:30
加拿大小哥哥
阅读(873)
评论(5)
推荐(0)