Skip to main content
  • Book
  • © 2019

The Joys of Hashing

Hash Table Programming with C

Apress

Authors:

  • Gives the pros and cons of different design choices when building tables
  • Walks you through the implementation of efficient hash tables
  • Contains a particular focus on teaching hash tables programming using the C programming language

Buy it now

Buying options

eBook USD 34.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book USD 44.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Other ways to access

This is a preview of subscription content, log in via an institution to check for access.

Table of contents (8 chapters)

  1. Front Matter

    Pages i-xi
  2. The Joys of Hashing

    • Thomas Mailund
    Pages 1-5
  3. Hash Keys, Indices, and Collisions

    • Thomas Mailund
    Pages 7-20
  4. Resizing

    • Thomas Mailund
    Pages 49-99
  5. Adding Application Keys and Values

    • Thomas Mailund
    Pages 101-137
  6. Heuristic Hash Functions

    • Thomas Mailund
    Pages 139-171
  7. Universal Hashing

    • Thomas Mailund
    Pages 173-198
  8. Conclusions

    • Thomas Mailund
    Pages 199-200
  9. Back Matter

    Pages 201-206

About this book

Build working implementations of hash tables, written in the C programming language. This book starts with simple first attempts devoid of collision resolution strategies, and moves through improvements and extensions illustrating different design ideas and approaches, followed by experiments to validate the choices. 


Hash tables, when implemented and used appropriately, are exceptionally efficient data structures for representing sets and lookup tables, providing low overhead, constant time, insertion, deletion, and lookup operations. 


The Joys of Hashing walks you through the implementation of efficient hash tables and the pros and cons of different design choices when building tables. The source code used in the book is available on GitHub for your re-use and experiments.


What You Will Learn
  • Master the basic ideas behind hash tables
  • Carry out collision resolution, including strategies for handling collisions and their consequences for performance
  • Resize or grow and shrink tables as needed
  • Store values by handling when values must be stored with keys to make general sets and maps

Who This Book Is For


Those with at least some prior programming experience, especially in C programming.

Authors and Affiliations

  • Aarhus N, Denmark

    Thomas Mailund

About the author

Thomas Mailund is an associate professor in bioinformatics at Aarhus University, Denmark. He has a background in math and computer science, including experience programming and teaching in C and R programming languages.  For the last decade, his main focus has been on genetics and evolutionary studies, particularly comparative genomics, speciation, and gene flow between emerging species.

Bibliographic Information

Buy it now

Buying options

eBook USD 34.99
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Softcover Book USD 44.99
Price excludes VAT (USA)
  • Compact, lightweight edition
  • Dispatched in 3 to 5 business days
  • Free shipping worldwide - see info

Tax calculation will be finalised at checkout

Other ways to access