medium of two sorted array of same size