Frage im Vorstellungsgespräch bei Tata Consultancy Services

A programming question about sorting matrix?