
Codeforces
文章平均质量分 87
muczzcy
这个作者很懒,什么都没留下…
展开
-
Codeforces Beta Round #1 A B C
A. Theatre Square 题目大意:给定n*m的正方形广场和a*a的砖,求最少要用多少砖才给覆盖整个广场。 解题思路:就是算在M边占据几个a,之后和N边占据几个a乘一下就好了, Answer = ceil(m/a) * ceil(n/a)。 #include #include #include using namespace std; long long n,m,a,ans原创 2013-01-31 17:10:17 · 367 阅读 · 0 评论 -
Codeforces Round #185 (Div. 1) && (Div. 2)
Div 2 A 模拟。模拟。模拟。我看错了一句话,最近总是犯这种毛病。。。According to his experience, he thought that Freda always said "lala."at the end of her sentences, while Rainbow always said "miao." at thebeginning of his sen原创 2013-05-27 18:09:38 · 616 阅读 · 0 评论 -
Codeforces Round #186 (Div. 2)
A 题水题,如果n #include #include using namespace std; int main() { int n,ans; scanf("%d",&n); if(n>=0) printf("%d\n",n); else { n=-n; ans=-(n/100*10+min(n%10,n/10%10)); pri原创 2013-05-31 08:33:44 · 1047 阅读 · 0 评论 -
Codeforces Round #166 (Div. 1) && (Div. 2)
D 题 SOL:就是要寻找满足某一条件的不同字串个数。 后缀数组解决!!! #include #include #include using namespace std; const int MAXN=2010; char r[MAXN]; int sa[MAXN]; int wa[MAXN],wb[MAXN],wv[MAXN],ws[MAXN];原创 2013-05-31 18:35:59 · 732 阅读 · 0 评论