trying to incorporate hash table