SHARE
TWEET

Untitled

a guest Jun 18th, 2019 47 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. /* a bucket is a linked list, each of whose entries contains a string and its hash */
  2.  
  3. typedef struct bucket bucket;
  4. struct bucket {
  5.   char *string;
  6.   unsigned long int hash;
  7.   bucket *next;
  8. };
  9. /* By convention, the empty bucket is NULL. */
  10.  
  11. typedef struct hash_table htbl;
  12. struct hash_table {
  13.   unsigned long int(*hash)(char*);
  14.   bucket **buckets; /* an array of buckets */
  15.   unsigned int n_buckets;
  16. };
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top