https://leetcode-cn.com/problems/merge-sorted-array/
题解
暴力解法
拼接之后直接排序
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.
"""
for i in range(n):
nums1[m+i] = nums2[i]
nums1.sort()