Citi interview question

Standard interview coding questions pretty much