Replaces array with hash table

Implementation with array replaced by hash tables, as given by library UThash.