摘要: #include#include#include#include#includeusing namespace std;struct Point{ double x,y; Point(double x=0,double y=0):x(x),y(y){}};typedef Point Ve... 阅读全文
posted @ 2014-08-21 14:00 JarvisLau 阅读(367) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#includeusing namespace std;struct Point{ int x,y; Point(int x=0,int y=0):x(x),y(y){}};typedef Point Vector;bool... 阅读全文
posted @ 2014-08-21 13:58 JarvisLau 阅读(170) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#includeusing namespace std;int gcd(int a,int b){ return a%b==0?b:gcd(b,a%b);}int main(){ int x1,x2,y1,y2; wh... 阅读全文
posted @ 2014-08-21 12:25 JarvisLau 阅读(210) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#includeusing namespace std;int main(){ int n; int a[6]; while(scanf("%d",&n)!=EOF) { for(int i=0;ians) ... 阅读全文
posted @ 2014-08-18 21:47 JarvisLau 阅读(123) 评论(0) 推荐(0) 编辑
摘要: 因为y已经排好序了,用x坐标建立一维树状数组#include#include#includeusing namespace std;int n;int a[32001];int lev[15001];int lowbit(int x){ return x&(-x);}int sum(int x... 阅读全文
posted @ 2014-08-11 18:20 JarvisLau 阅读(121) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#includeusing namespace std;struct Point{ int x,y; Point(int x=0,int y=0):x(x),y(y){}};typedef Point Vector;bool... 阅读全文
posted @ 2014-08-11 10:03 JarvisLau 阅读(216) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#includeusing namespace std;double a[10010][150];double dp[10010][150];int b[10010];int n;void solve(int cnt){ memset(dp,0,... 阅读全文
posted @ 2014-08-10 07:37 JarvisLau 阅读(128) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#define lson l,m,rt> 1)) * col[rt]; sum[rt> 1) * col[rt]; col[rt] = 0; }}void build(int l,int r,int rt){ c... 阅读全文
posted @ 2014-08-09 19:58 JarvisLau 阅读(150) 评论(0) 推荐(0) 编辑
摘要: #include#include#include#include#define lson l,m,rt=p) { update(v,p,lson); } else { p-=sum[rt>n) { for(int i=0; i=... 阅读全文
posted @ 2014-08-09 12:50 JarvisLau 阅读(122) 评论(0) 推荐(0) 编辑
摘要: 一道模拟题,写的有点麻烦#include#include#include#include#includeusing namespace std;bool fun(char c){ if(c=='a'||c=='A'||c=='e'||c=='E'||c=='i'||c=='I'||c=='o'... 阅读全文
posted @ 2014-08-08 21:11 JarvisLau 阅读(140) 评论(0) 推荐(0) 编辑