Please Help-- I am new to Codechef

I am getting a wrong answer. My link to solution is http://www.codechef.com/viewsolution/5907104.
please help. Thanks :)`

you have done mod of 10^5 but in question it is given 10^6.

If you don’t mind, please write the question name also.

Team Split
Problem code: TMSLT

So, that every one can see of what question you are asking.
Happy coding :slight_smile:

Team Split Problem code: TMSLT

Still getting wrong answer :frowning:

Link http://www.codechef.com/viewsolution/5927322

Check the editorial here

you should have stored the strength calculated in an array and then sort in reverse order and then you should have used condition
" if(n1%2==0) t1+=arr[n1];
else t2+=arr[n1];"