O'Reilly logo
  • VISDA VOKHSHOORI thinks this is interesting:

unsigned int hash(int keyvalue) { return (key % HASH_ARRAY_SIZE); }

From

Cover of C++ Footprint and Performance Optimization

Note

key is an undefined variable. It must have been a typo. It should (keyvalue % HASH_ARRAY_SIZE)