The Trade Desk Interview Question

Write a sorting algorithm for a string.