02 2016 档案
bzoj1040: [ZJOI2008]骑士
摘要:1 #include<cstdio> 2 #include<iostream> 3 #define M 1000001 4 using namespace std; 5 int head[M],next[M],u[M],n,v[M],fa[M],cnt,q[M],f1[M],xia[M],ans; 阅读全文
posted @ 2016-02-29 23:01 xiyuedong 阅读(144) 评论(0) 推荐(0)
bzoj 1031: [JSOI2007]字符加密Cipher
摘要:1 #include<cstdio> 2 #include<iostream> 3 #include<cstring> 4 #define N 200005 5 using namespace std; 6 int a[N],v[N],sa[2][N],rk[2][N],n,k; 7 char ch 阅读全文
posted @ 2016-02-29 22:53 xiyuedong 阅读(146) 评论(0) 推荐(0)
bzoj 1030: [JSOI2007]文本生成器
摘要:1 #include<cstdio> 2 #include<cstring> 3 #include<iostream> 4 using namespace std; 5 char ch[105],s[106]; 6 int n,m,a[6007][27],size=1,fail[6007],dui[ 阅读全文
posted @ 2016-02-29 22:49 xiyuedong 阅读(130) 评论(0) 推荐(0)
bzoj 1022: [SHOI2008]小约翰的游戏John
摘要:1 #include<cstdio> 2 #include<iostream> 3 using namespace std; 4 int T,a[100],n; 5 int main() 6 { 7 scanf("%d",&T); 8 for(;T;T--) 9 { 10 int a1=0,kg=0 阅读全文
posted @ 2016-02-29 11:47 xiyuedong 阅读(155) 评论(0) 推荐(0)
bzoj 1015: [JSOI2008]星球大战starwar
摘要:1 #include<cstdio> 2 #include<iostream> 3 #define M 2000000 4 int cnt,fa[M],n,m,ans[M],k,f[M],a[M],head[M],next[2*M],u[2*M]; 5 int zhao(int a1) 6 { 7 阅读全文
posted @ 2016-02-29 11:25 xiyuedong 阅读(178) 评论(0) 推荐(0)
bzoj 1013: [JSOI2008]球形空间产生器sphere
摘要:1 #include<iostream> 2 #include<cstdio> 3 #include<cmath> 4 #define eps 1e-6 5 #define M 15 6 using namespace std; 7 double a[M],b[M][M]; 8 int n; 9 i 阅读全文
posted @ 2016-02-29 11:19 xiyuedong 阅读(164) 评论(0) 推荐(0)
bzoj 1012: [JSOI2008]最大数maxnumber
摘要:1 #include<cstdio> 2 #include<iostream> 3 #include<algorithm> 4 #define M 200008 5 using namespace std; 6 int a[M],n,b[M],d,t,h,len; 7 char ch[10]; 8 阅读全文
posted @ 2016-02-28 06:37 xiyuedong 阅读(189) 评论(0) 推荐(0)
bzoj 1010: [HNOI2008]玩具装箱toy
摘要:1 #include<cstdio> 2 #include<iostream> 3 #define M 50005 4 using namespace std; 5 long long sum[M],f[M],n,L,q[M],h,t,C; 6 double gg(int x,int y) 7 { 阅读全文
posted @ 2016-02-28 06:31 xiyuedong 阅读(161) 评论(0) 推荐(0)
bzoj 1008: [HNOI2008]越狱
摘要:1 #include<cstdio> 2 #include<iostream> 3 using namespace std; 4 long long n,m,ans=1,ans1=1,n1; 5 int main() 6 { 7 scanf("%lld%lld",&m,&n); 8 n--; 9 l 阅读全文
posted @ 2016-02-27 22:37 xiyuedong 阅读(142) 评论(0) 推荐(0)
bzoj 1007: [HNOI2008]水平可见直线
摘要:1 #include<cstdio> 2 #include<iostream> 3 #include<algorithm> 4 #define M 1000000 5 using namespace std; 6 struct data 7 { 8 int k,b,nu; 9 }a[M]; 10 i 阅读全文
posted @ 2016-02-27 22:35 xiyuedong 阅读(170) 评论(0) 推荐(0)
bzoj 1005: [HNOI2008]明明的烦恼
摘要:1 #include<cstdio> 2 #include<iostream> 3 #define M 10005 4 int a[M],n,d[M],f[M],b[M],tot,m; 5 void jia(int a1) 6 { 7 for(int i=1;i<=d[0];i++) 8 for(; 阅读全文
posted @ 2016-02-27 22:29 xiyuedong 阅读(174) 评论(0) 推荐(0)
bzoj 1003: [ZJOI2006]物流运输trans
摘要:1 #include<cstdio> 2 #include<queue> 3 #include<iostream> 4 #include<cstring> 5 #define M 1000 6 using namespace std; 7 int n,m,k,e,cnt,head[M],next[2 阅读全文
posted @ 2016-02-27 22:22 xiyuedong 阅读(180) 评论(0) 推荐(0)
bzoj 1002: [FJOI2007]轮状病毒
摘要:基尔霍夫矩阵(我也不知道是什么)推出f[i]=(f[i-1]*3-f[i-2]+2)(这其实是我抄的) 还是要高精的。 1 #include<cstdio> 2 #include<iostream> 3 using namespace std; 4 int f[102][102],n; 5 void 阅读全文
posted @ 2016-02-27 21:58 xiyuedong 阅读(164) 评论(0) 推荐(0)
bzoj 1001: [BeiJing2006]狼抓兔子
摘要:把所有的边建出来后跑最小割,题目是最小割并不难理解 1 #include<cstdio> 2 #include<iostream> 3 #include<cstring> 4 #include<queue> 5 #define M 1000009 6 using namespace std; 7 i 阅读全文
posted @ 2016-02-27 21:45 xiyuedong 阅读(227) 评论(0) 推荐(0)
bzoj 1000: A+B Problem
摘要:刚学编程就会的题,如果你有闲情逸致可以用网络流打 1 #include<cstdio> 2 #include<iostream> 3 int main() 4 { 5 int a,b; 6 scanf("%d%d",&a,&b); 7 printf("%d",a+b); 8 return 0; 9 阅读全文
posted @ 2016-02-27 21:40 xiyuedong 阅读(111) 评论(0) 推荐(0)