Hi Guys,
I hope u are doing well
Actually
I cant understand why my code gives WA on 47 testcase
Even when my code is almost similar to the editorialist's code,
The testcase :
29 425 46 81
405 237 24 45 165 328 134 309 7 236 348 204 368 396 298 343 180 186 395 246 44 53 303 404 271 344 269 292 12
Actual answer : 2
Mycode's output : 1
Problem E Div 3 : https://codeforces.net/contest/1324/problem/E
My code Link : https://codeforces.net/contest/1324/submission/80940535
Editorial Link : https://codeforces.net/blog/entry/74714
Please give it a try.
Thanks in Advance.