August Lunch Time 2019 TRIP2

i dont know i m getting wrong answer
here is the link of my code
Please look into this
https://www.codechef.com/viewsolution/26178885

Your solution fails for the testcase:

1
10 2
-1 -1 -1 -1 -1 2 -1 -1 -1 2 
2 Likes