Ubisoft interview question

basic sorting algorithm