you give integer array nums1 nums2 sort nondecrease order integer m n represent number element nums1 nums2 respectivelyMerge nums1 nums2 single array sort nondecrease orderthe final sorted array return function instead store inside array nums1 to accommodate nums1 length m n m element denote element merge n element set 0 ignore nums2 length n example 1input nums1 123000 m 3 nums2 256 n 3output 122356explanation the array merge 123 256the result merge 122356 underline element come nums1Example 2input nums1 1 m 1 nums2 n 0output 1explanation the array merge 1 the result merge 1example 3input nums1 0 m 0 nums2 1 n 1output 1explanation the array merge 1the result merge 1note m 0 element nums1 the 0 ensure merge result fit nums1 Constraintsnums1length m nnums2length n0 m n 2001 m n 200109 nums1i nums2j 109 Follow can come algorithm run Om n time