refine Median of two sorted arrays