[LeetCode] 88. Merge Sorted Array
Python
class Solution:
def merge(self, nums1: List[int], m: int, nums2: List[int], n: int) -> None:
"""
Do not return anything, modify nums1 in-place instead.
"""
del nums1[m:]
nums1 += nums2[:n]
nums1.sort()
댓글남기기