Help -- KRILLIN problem getting WA

Link to problem : https://www.codechef.com/QUCO2018/problems/KRILLIN

My submission : https://www.codechef.com/viewsolution/18905601

Getting WA – need help

EDIT : It’s accepted now. Did a very silly mistake of specifying wrong datatype in getKth function where I wrote int K and the only fix required was long long K – but it took many hours to observe this :frowning: