A. Bus to Udayland time limit per test 2 seconds memory limit per test 256 megabytes input standard input output standard output ZS the Coder and Chris the Baboon are travelling to Udayland! To get there, they have to get on the special IOI bus. The…
A. Cakeminator time limit per test 1 second memory limit per test 256 megabytes input standard input output standard output You are given a rectangular cake, represented as an r × c grid. Each cell either has an evil strawberry, or is empty. For exam…
Write an efficient algorithm that searches for a value in an m x n matrix. This matrix has the following properties: Integers in each row are sorted from left to right. The first integer of each row is greater than the last integer of the previous ro…
Secret agent Maria was sent to Algorithms City to carry out an especially dangerous mission. After several thrilling events we find her in the first station of Algorithms City Metro, examining the time table. The Algorithms City Metro consists of a s…