Ivan Mistreanu's submission of Witua and Math | CodeChef