Codeforces Round #158 (Div. 2)
轉載請註明出處,謝謝http://blog.csdn.net/ACM_cxlove?viewmode=contents by---cxlove
總體來說,這場不是很好做啊,對於div2
A:顯然新增第一位之後如果整除的話,那麼之後全新增0的就行了。反過來,如果第一位不滿足的話,那麼畢竟不行。
那麼考慮 (b-a*10%b)是否小於10就行了
B:列舉以每一個字元開始的長度 為10的串,然後進行分解,判斷,map搞一下
C:這個題嘛,要考慮球最少的那個盒子。起點只可能是在球最少的盒子處,不是嗎?
然後我們就從終態往前堆到最少的盒子處,有多個也沒事,隨意取一個
那麼中間部分就要全部減1,然後根據最少盒子裡的數量就知道中間運轉了多少輪,倒推就OK了
D:貪心吧,直接推。將點分為兩堆0,1。先考慮權值小的點
從兩堆中各取一個,邊權便是兩者權值的最小值。然後判斷是否還剩。
但是有一種情況要注意,如果兩個點的邊權一樣,這時候不能把這兩個點都拋棄。
應該選擇一個拋棄,不然就不連通了,也就是之前的點和之後的點不連通,保證有一個點留下和接下來的點繼續連線
E:列舉所有情況,然後線段樹判斷
相關文章
- Codeforces Round #639 (Div. 2)
- Codeforces Round #541 (Div. 2)
- Codeforces Round #682 (Div. 2)
- Codeforces Round #678 (Div. 2)
- Codeforces Round #747 (Div. 2)
- Codeforces Round #673 (Div. 2)
- Codeforces Round #672 (Div. 2)
- Codeforces Round #448 (Div. 2) A
- Codeforces Round #217 (Div. 2)
- Codeforces Round #256 (Div. 2)
- Codeforces Round #259 (Div. 2)
- Codeforces Round #257 (Div. 2)
- Codeforces Round #258 (Div. 2)
- Codeforces Round #171 (Div. 2)
- Codeforces Round #173 (Div. 2)
- Codeforces Round 932 (Div. 2)
- Codeforces Round 934 (Div. 2)
- Codeforces Round 940 (Div. 2)
- Codeforces Round #448 (Div. 2)B
- Codeforces Round #227 (Div. 2)
- Codeforces Round #215 (Div. 2)
- Codeforces Round #221 (Div. 2)
- Codeforces Round #219 (Div. 2)
- Codeforces Round #453 (Div. 2) C
- Codeforces Round #450 (Div. 2) B
- Codeforces Round #452 (Div. 2) C
- Codeforces Round #452 (Div. 2) D
- Codeforces Round #268 (Div. 2)
- Codeforces Round #260 (Div. 2)
- Codeforces Round #181 (Div. 2)
- Codeforces Beta Round #14 (Div. 2)
- Codeforces Round #169 (Div. 2)
- Codeforces Round #166 (Div. 2)
- Codeforces Round 936 (Div. 2) E
- Codeforces Round 892 (Div. 2) E
- Codeforces Round 941 (Div. 2) D
- codeforces Educational Codeforces Round 33 (Rated for Div. 2)
- 【Codeforces Round #429 (Div. 2) A】Generous Kefa