I tried this problem on codechef.https://www.codechef.com/LRNDSA07/problems/FROGV/. but I getting a wrong answer. this is the code I tried . code
n,k,p=map(in