Code not running

can you please check my code. It is not showing any answer.

int s=arr[n-1]; this statement is wrong

s should be the max element of the array
so s is computed as
for(int x: arr)
s = max( s, x) ;

sir still not running

apply a new line character after each test case

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.