Spotify interview question

Live code to sort a multi dimensional array with least time complexity