Dinesh Goyal's submission of Bad Luck | CodeChef