My solution for http://www.codingame.com/