Citi Interview Question

Data structure and Algorithm related.