The given test case for A : [ 4, 9, 13, 15, 6 ] has expected output of 109 but my code returns a value 104. I checked that 104 is possible if we consider 4+6 first = 10, then 10+9 = 19, then 13+15=28 , then 28+19=47

Total Cost = 10+19+28+47 = 104.

Can someone explain how 109 is minimum??