How to solve The Lead Game?

Can someone please point out what I am doing wrong in this code.

Solution

You read the question Wrong.
Please read the problem once again and try the understand. It wants maximum difference between leads ( i.e. Cumulative sum of scores ).
Click Here to View My solution
Click Here for Editorial

//