Pergunta de entrevista da empresa Genentech

How would you write a sorting function?