Solution for Alpha 2010 task