I was soling the wrong problem due to bad wording. Please fix it!!!


  • 1
    G

    "....you can split the array into m non-empty continuous subarrays"
    I understood this to be.. that the subarrays themselves have to be continues (e.g. 1,2,3,4...)
    The wording should be changed to prevent ambiguities.


  • 0

    How about just changing the example to something like [7,2,5,10,8], 2 (which has answer 18 due to [7,2,5] + [10,8])?


  • 0

    @StefanPochmann Thanks, I have updated the problem description using your example to avoid misunderstanding.


Log in to reply
 

Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.