I have attached 3 screenshots, one in local, another in CodeChef online compiler as well as submission on code forces. for Testcase 2 — case 4, gives correct output as expected in codechef online compiler as well as in local, but gives the wrong answer in codeforces submission. Can anyone please help.
question link : https://mirror.codeforces.com/contest/1737/problem/B submission : https://mirror.codeforces.com/contest/1737/submission/175028607