LeetCode-4:Median of Two Sorted Arrays

一、题目

原题链接:https://leetcode.com/problems/median-of-two-sorted-arrays/description/
难度等级:困难

There are two sorted arrays nums1 and nums2 of size m and n respectively.

Find the median of the two sorted arrays. The overall run time complexity should be O(log (m+n)).

Example 1:

nums1 = [1, 3]
nums2 = [2]
The median is 2.0

Example 2:

nums1 = [1, 2]
nums2 = [3, 4]

The median is (2 + 3)/2 = 2.5

题目翻译:
有两个大小为 m 和 n 的排序数组 nums1 和 nums2 。

请找出两个排序数组的中位数并且总的运行时间复杂度为 O(log (m+n))


二、解题方案

(待完善。。。)

你可能感兴趣的:(LeetCode题解,LeetCode题解)