Lenze interview question

problem solving using Arraylist, string, Hashmap