- 博客(23)
- 收藏
- 关注
原创 Educational Codeforces Round 18 (A+B+C)
A. New Bus Route time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output There are n cities situated along the main road of Berland. Cities are rep
2017-03-28 14:47:02 682
转载 Codeforces Round #406 (Div. 2) C. Berzerk(有向图博弈)
C. Berzerk time limit per test4 seconds memory limit per test256 megabytes inputstandard input outputstandard output Rick and Morty are playing their own version of Berzerk (which has nothing in c
2017-03-26 19:31:46 636
转载 Codeforces Round #406 (Div. 2) E. Till I Collapse
E. Till I Collapse time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Rick and Morty want to find MR. PBH and they can’t do it alone. So they
2017-03-25 23:57:28 818
原创 Codeforces Round #406 (Div. 2)A+B(这鬼畜的英文)
A. The Monster time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output A monster is chasing after Rick and Morty on another planet. They’re so frig
2017-03-24 20:44:37 1436
原创 E. Anton and Permutation (树状数组+主席树)
E. Anton and Permutation time limit per test4 seconds memory limit per test512 megabytes inputstandard input outputstandard output Anton likes permutations, especially he likes to permute their el
2017-03-23 22:32:03 825
原创 支持修改的主席树,例题:zoj2112
一些名字和解释:传送门 例题:zoj2112 代码:#include <bits/stdc++.h>#define ll long longusing namespace std;const int N=60060;int cnt,n,m,x,y,k,tmp,root[N],spt[N],a[N];int cmp;struct node{int l,r,sum;}T[N*40];s
2017-03-21 20:11:24 538
原创 预处理C(n,m)
LL fac[1000005]; //阶乘LL inv_of_fac[1000005]; //阶乘的逆元LL qpow(LL x,LL n){ LL ret=1; for(; n; n>>=1) { if(n&1) ret=ret*x%mod; x=x*x%mod; } return r
2017-03-19 20:53:58 709
原创 Codeforces Round #405(A+B(图论)
A. Bear and Big Brother time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Bear Limak wants to become the largest of bears, or at least to bec
2017-03-19 20:34:43 645
原创 Codeforces Round #405 C. Bear and Different Names (思维)
C. Bear and Different Names time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output In the army, it isn’t easy to form a group of soldiers that wil
2017-03-19 12:14:28 627
转载 Codeforces Round #404 (Div. 2)E. Anton and Permutation(分块)
E. Anton and Permutation time limit per test4 seconds memory limit per test512 megabytes inputstandard input outputstandard output Anton likes permutations, especially he likes to permute their el
2017-03-18 22:54:21 697
转载 Codeforces Round #404 (Div. 2) D. Anton and School - 2(组合数学)
D. Anton and School - 2 time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output As you probably know, Anton goes to school. One of the school subj
2017-03-17 23:19:57 691
原创 Codeforces Round #404 (Div. 2) C. Anton and Fairy Tale(二分)
C. Anton and Fairy Tale time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Anton likes to listen to fairy tales, especially when Danik, Anton’
2017-03-17 00:01:02 555
原创 Codeforces Round #404 (Div. 2)(A+B)
A. Anton and Polyhedrons time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Anton’s favourite geometric figures are regular polyhedrons. Note
2017-03-16 21:47:17 350
原创 Hrbust 2054 Boring Counting (主席树+二分)
Boring Counting Time Limit: 3000 MS Memory Limit: 32768 K Total Submit: 67(21 users) Total Accepted: 5(5 users) Rating: Special Judge: No Description In this problem you are given a number sequence P
2017-03-13 15:44:07 426
转载 Codeforces Round #403 (Div. 2)C Andryusha and Colored Balloons (dfs)
C. Andryusha and Colored Balloonstime limit per test:2 secondsmemory limit per test:256 megabytesinput:standard inputoutput:standard outputAndryusha goes through a park each day. The squares and paths
2017-03-09 21:39:24 445
原创 Codeforces Round #403 (Div. 2)A+B
A. Andryusha and Sockstime limit per test:2 secondsmemory limit per test:256 megabytesinput:standard inputoutput:standard outputAndryusha is an orderly boy and likes to keep things in their place.Today
2017-03-09 21:21:18 288
转载 2016zzuli校赛G题 《蛤玮点菜》(中途相遇法)
Description在我们下饭店的时候蛤玮经常负责点菜,今天饭店搞活动,当总价格大于等于X时可以减去Y的优惠,注意如果总价是2X也仅减去一倍Y.蛤玮非常了解菜品也了解大家,他知道每个菜品有一个饱食度,只有菜品饱食度的和不小于K时大家才会吃的开心.请问蛤玮如何点菜才能在让大家吃的开心的前提下花尽量少的钱,输出最后需要付的钱.注意蛤玮是个有追求的人,所以他不会点重复的菜. InputT(1<=T<=
2017-03-09 20:55:07 387
原创 2016zzuli校赛D题《蛤玮打扫教室》(线段树)
题意:给出n个房间m个人,每个人需要打扫[l,r]的房间。问有几个队可以偷懒不用干活 代码:#include<stdio.h>#include<stdlib.h>#include<algorithm>#include<iostream>#include<vector>#include<map>#include<math.h>#include<string.h>#define ll
2017-03-05 03:53:33 901
原创 Codeforces Round #402 (Div. 2) D. String Game(二分)
D. String Gametime limit per test:2 secondsmemory limit per test:512 megabytesinput:standard inputoutput:standard outputLittle Nastya has a hobby, she likes to remove some letters from word, to obtain
2017-03-02 17:26:02 186
原创 Codeforces Round #402 (Div. 2)C. Dishonest Sellers (贪心)
C. Dishonest Sellerstime limit per test:2 secondsmemory limit per test:256 megabytesinput:standard inputoutput:standard outputIgor found out discounts in a shop and decided to buy n items. Discounts at
2017-03-02 16:44:23 548
原创 Codeforces Round #402 (Div. 2) A+B
A. Pupils Redistributiontime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputIn Berland each high school student is characterized by academic perform
2017-03-02 16:40:38 376
原创 Codeforces Round #401 (Div. 2)E. Hanoi Factory(离散化+线段树)
E. Hanoi Factorytime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputOf course you have heard the famous task about Hanoi Towers, but did you know th
2017-03-01 21:54:42 294
原创 Codeforces Round #401 (Div. 2 )E. Hanoi Factory
E. Hanoi Factorytime limit per test:1 secondmemory limit per test:256 megabytesinput:standard inputoutput:standard outputOf course you have heard the famous task about Hanoi Towers, but did you know th
2017-03-01 12:47:34 488
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人