The code run in python and vs code gives the right answer(case2,2.5) but in leetcode always wrong(2.0).
Some accepted solutions fail on certain edge cases because they don’t properly handle arrays where all elements are the same or where negative numbers are included. These cases are not covered in the ...