Reddit interview question

Coding question involving some sorting. I can't remember the exact question.