Adding medians of two sorted by arrays