apple pie's submission of Dominant Army | CodeChef