I feel like there's something wrong with this question, or maybe I didn't understand it well.
With this input [1,2], 0, [2,4], 1, it says that my answer is [1,2] and the expected is [2,2].
First, when I run it, I get , not [1,2]. Second, why should I expect [2,2]? Why 0 and 1 should output the last elem in my first array and the first in my second? Can someone shed some light on this ? :)
class Solution(object): def merge(self, nums1, m, nums2, n): nums1 = nums1[0:m] + nums2[0:n]