Only one test case passed

it is not necessary that the first player will choose max of first and last coin

see this example
1 4 8 3
here if first player choose 3 then he is in loss
to get more coins player 1 should choose 1

1 Like

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.