A. Chaitanya Kumar's submission of Mahasena | CodeChef