Pergunta de entrevista da empresa Cognizant

They gave an example of a SQL database with different classrooms with different students and asked how I would sort the students by classroom.