put and search in hashmap completed