ABC Interview Question

Question related to data structures