Bank of America interview question

Data structure and algorithms in detail