manas agrawal's submission of Daily Train | CodeChef