上一页 1 ··· 6 7 8 9 10 11 12 13 下一页

2016年4月11日

三个水杯

摘要: 1 #include <cstdio> 2 #include <cstring> 3 #include <queue> 4 5 using namespace std; 6 struct node { 7 int wat[3]; //记录中间过程状态 8 int step;//最小倒水次数。 9 } 阅读全文

posted @ 2016-04-11 11:18 青春的梦想付诸行动 阅读(120) 评论(0) 推荐(0)

2016年4月10日

部分和

摘要: 1 #include <iostream> 2 #include <cstdio> 3 #include <algorithm> 4 #include <cmath> 5 #include <cstring> 6 7 using namespace std; 8 int n,k,c,sum,s[20 阅读全文

posted @ 2016-04-10 21:51 青春的梦想付诸行动 阅读(154) 评论(0) 推荐(0)

2016年4月9日

BestCoder Round #79 jrMz and angles

摘要: 1 #include <iostream> 2 #include <cstdio> 3 #include <cmath> 4 5 using namespace std; 6 7 int main() 8 { 9 int n,m,t,flag; 10 double a,b; 11 scanf("%d 阅读全文

posted @ 2016-04-09 20:27 青春的梦想付诸行动 阅读(202) 评论(0) 推荐(0)

2016年4月8日

Yougth的最大化

摘要: 1 #include <iostream> 2 #include <cstdio> 3 #include <algorithm> 4 #include <cmath> 5 6 using namespace std; 7 8 #define N 10010 9 10 double w[N],v[N] 阅读全文

posted @ 2016-04-08 19:30 青春的梦想付诸行动 阅读(413) 评论(0) 推荐(0)

疯牛

摘要: 1 #include<iostream> 2 #include<algorithm> 3 #include<cmath> 4 #include<cstdio> 5 using namespace std ; 6 typedef long long LL; 7 LL a[101000]; 8 int 阅读全文

posted @ 2016-04-08 11:18 青春的梦想付诸行动 阅读(137) 评论(0) 推荐(0)

2016年4月7日

阶乘之和

摘要: 1 #include <iostream> 2 #include <cstdio> 3 #include <algorithm> 4 using namespace std; 5 int s[11]; 6 bool visit[11]; 7 void ans() 8 { 9 for(int i=1; 阅读全文

posted @ 2016-04-07 15:55 青春的梦想付诸行动 阅读(148) 评论(0) 推荐(0)

NYOJ 12 喷水装置(二)

摘要: 1 #include<stdio.h> 2 #include<string.h> 3 #include<math.h> 4 #include<algorithm> 5 using namespace std; 6 struct ps 7 { 8 double left;//**左交点**// 9 d 阅读全文

posted @ 2016-04-07 11:54 青春的梦想付诸行动 阅读(224) 评论(0) 推荐(0)

2016年2月24日

KMP AC自动机算法

摘要: 在KMP算法中,为了确定在匹配不成功时,下次匹配时j的位置,引入了next[]数组,next[j]的值表示P[0...j-1]中最长后缀的长度等于相同字符序列的前缀。 对于next[]数组的定义如下: 1) next[j] = -1 j = 0 2) next[j] = max(k): 0<k<j 阅读全文

posted @ 2016-02-24 13:35 青春的梦想付诸行动 阅读(422) 评论(0) 推荐(0)

2016年2月15日

算法训练 P1103

摘要: 复数运算规则: 乘法法则规则: 规定复数的乘法按照以下的法则进行: 设z1=a+bi,z2=c+di(a、b、c、d∈R)是任意两个复数,那么它们的积(a+bi)(c+di)=(ac-bd)+(bc+ad)i. 其实就是把两个复数相乘,类似两个多项式相乘,展开得:ac+adi+bci+bdi^2,因 阅读全文

posted @ 2016-02-15 22:52 青春的梦想付诸行动 阅读(687) 评论(0) 推荐(0)

安慰奶牛

摘要: 传送门 :安慰奶牛 1 #include<iostream> 2 #include<cstdio> 3 #include<algorithm> 4 #include<cstdlib> 5 6 using namespace std; 7 8 struct node{ 9 int x,y,w; 10 阅读全文

posted @ 2016-02-15 00:46 青春的梦想付诸行动 阅读(168) 评论(0) 推荐(0)

上一页 1 ··· 6 7 8 9 10 11 12 13 下一页

导航