Hexaware Technologies Interview Question

Given a set columns, sort it in some specific order ? For example, a student data with marks, register number, height etc,. sort by descending marks .if marks are same, sort by ascending register number etc. (Coding Round Question)