Bloomberg interview question

algorithms