In Problem D for the first test case (last case)
6 1 6 3 4 5 6 My answer was 10 everywhere (I tried on VsCode, GFG ide, Codechef ide) but when I was submitting it on Codeforces it was showing 16 and it wasted all of my time. Can Anyone please tell me what could be the probable reason?