3 ms·
Are you able to solve it? (from the teenagers programming contest)
- kuszi 15y agoThe official contest is over but you can try out here: http://www.spoj.pl/HSPLARCH/problems/HS11CNSM/ http://www.spoj.pl/HSPLARCH/problems/HS11CNSM/
- _THE_PLAGUE 15y agoSeems like this is something like P = ((N * M) - (N + M - 1))/K but haven't tried out too many cases.
- kuszi 15y agoa solution given by the contestant: http://bit.ly/rTrO87 http://bit.ly/rTrO87