Citi interview question

data structure and algorithms basics