Invalid Expected Output java

The output should be remaining length of list but expected out is showing list element.
Preformatted textYour submission failed for the following input:

A : [ 5000, 5000, 5000 ]

Your function returned the following :

5000 5000 5000

The expected returned value :


You should use the .equals() method instead of ==

Click here to start solving coding interview questions