Pregunta de entrevista de Principal Financial Group

Gave an array. write a code to sort in ascending order.