Deliveroo interview question

Simple Hashmap dictionary question to maintain the counts