Test-case-1 for the problme of max value array

can you please tell me what is the test case 1 for the following problem

hello @pradyumn25jain ,
the issue is in ur code.

ur code is printing 0 for the case where all elements of array are negative.

to rectify it initialise ur max variable with the value of any element of ur array .

1 Like