LinkedIn Interview Question

Object and array - answer is to use hashmap. Similar to two sum