basic implementation of a hashtable