Abhishek Pal's submission of Mahasena | CodeChef