Incorrect test cases

Incorrect test cases are provided for the problem
As rightly pointed, -2 -1 -1 4 should have 8 as output and not 6

it is supposed to be 6 -2(2),-1(1),-1(1),4(2) -> 2+1+1+2=6

No it should be -2(1) -1(2) -1(1) 4(2) Total = 6

Click here to start solving coding interview questions