Barclays interview question

Basics Java questions Hashmap implementation