time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output After seeing the "ALL YOUR BASE ARE BELONG TO US" meme for the first time, numbers X and Y realised that they have different bases, which co…
http://acm.hust.edu.cn/vjudge/contest/view.action?cid=102271#problem/C Description After seeing the "ALL YOUR BASE ARE BELONG TO US" meme for the first time, numbers X and Y realised that they have different bases, which complicated their relati…
time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Galya is playing one-dimensional Sea Battle on a 1 × n grid. In this game a ships are placed on the grid. Each of the ships consists of b consecu…
time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Amr lives in Lala Land. Lala Land is a very beautiful country that is located on a coordinate line. Lala Land is famous with its apple trees grow…
time limit per test1 second memory limit per test256 megabytes inputstandard input outputstandard output Just to remind, girls in Arpa's land are really nice. Mehrdad wants to invite some Hoses to the palace for a dancing party. Each Hos has some wei…
time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Ohana Matsumae is trying to clean a room, which is divided up into an n by n grid of squares. Each square is initially either clean or dirty. Oh…