Code on pc working fine , but not online

Tags: #<Tag:0x00007f2424cea1e0>


My code s giving correct answer on my pc . but it is not giving correct online. dont know why it is happening


Check Your PC. @aman_dhapola_934


same happened with me in test case -4, -2, 0, -6, -1


Oh i got it, somewhere the iterator will be out of bound, which is ignored by your ide’s compiler but not in interview bit’s compiler