Shayan's submission of SubInversing | CodeChef