David's submission of A Puzzle | CodeChef