摘要:
http://codeforces.com/gym/101615/attachments 除了除法分块,还需要注意的是一定要用 unsigned 否则会wa。 阅读全文
摘要:
Cersei and Jaime has stolen n gold coins from the Casterly Rock reserves. They decided to play a game while the disappearence is not detected. The gam 阅读全文
摘要:
The day of opening of the greatest shop in the world is coming. To show the full potential of their shop, in particular, the unbelievable speed of the 阅读全文
摘要:
Pavel loves Far Manager very much. By default, Far shows files in a certain number of columns each of which holds p files. Besides, there is also a «z 阅读全文
摘要:
1 #include<bits/stdc++.h> 2 3 using namespace std; 4 5 vector<int> ve[1000005]; 6 int a[1000005]; 7 8 struct node 9 { 10 int id; 11 int num; 12 int jieguo; 13 }s[1000005]; 14 15 bool cmp(node a, node 阅读全文
摘要:
1 #include <stdio.h> 2 #include <string.h> 3 4 int main() 5 { 6 long long n, x, sum; 7 scanf("%lld", &n); 8 x = n; 9 10 sum = 0; 11 while(x>0) 12 { 13 sum = sum + (x%10) * (x%10); 14 x /= 10; 15 } 16 阅读全文
摘要:
http://codeforces.com/gym/101341/problem/B ProblemB. Pursuing the HappinessInput file: standard inputOutput file: standard outputTime limit: 2 seconds 阅读全文
摘要:
http://codeforces.com/gym/101341/problem/D A frog lives in a one-dimensional world in the point with the coordinate 0. He needs to get to the point wi 阅读全文
摘要:
A digit sum S_b(n)Sb(n) is a sum of the base-bb digits of nn. Such as S_{10}(233) = 2 + 3 + 3 = 8S10(233)=2+3+3=8, S_{2}(8)=1 + 0 + 0 = 1S2(8)=1+0+ 阅读全文
摘要:
There are NN light bulbs indexed from 00 to N-1N−1. Initially, all of them are off. A FLIP operation switches the state of a contiguous subset of bulb 阅读全文