Cimpress interview question

Write a function to sort an array