Some natural number was written on the board. Its sum of digits was not less than k. But you were distracted a bit, and someone changed this number to n, replacing some digits with others. It's known that the length of the number didn't change. You h…
There are n people and k keys on a straight line. Every person wants to get to the office which is located on the line as well. To do that, he needs to reach some point with a key, take the key and then go to the office. Once a key is taken by somebo…
Arkady needs your help again! This time he decided to build his own high-speed Internet exchange point. It should consist of n nodes connected with minimum possible number of wires into one network (a wire directly connects two nodes). Exactly k of t…
题目链接:http://codeforces.com/problemset/problem/93/B B. End of Exams time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output Students love to celebrate their holidays. Especially if the holiday is th…