saegusa's submission of Pishty and tree | CodeChef