In example 1 end should be 5(not 4) since there are total 5 elements. Find median of two sorted arrays of different sizes. Algorithm is based on binary search.

Nguồn:https://mcitmc.org/