medium of two sorted array