Median of two arrays
Your task
Given two sorted integer arrays a and b, return the median of the combined sorted array as a float. Either array may be empty (but not both). The combined length is at least 1. Return a float (e.g. 2.0 or 2.5).
Examples
median_two_sorted(a: list[int], b: list[int]) -> floatExample 1
Input
median_two_sorted([1, 3], [2])Output
2