Bloomberg interview question

leetcode medium style questions in the technical rounds