My soln for this Solution: 41769017 | CodeChef

Problem Link - Contest Page | CodeChef

I cant find any other test case in which my code fails.

Can any1 give other test case?

Logic - Just merge all the adjacent positive numbers in the array. From this array, take the negative element one by one and try to check in left and right upto k negative numbers, if present, on both sides and calculate the sum using prefix sums.