MedExpert interview question

Sort algorithm, 2 dimension array