To sort a list of numbers