Hashing: A Study Guide
Hash tables and hash sets: how hashing works, operations and Big-O, a Python example, collisions and other pitfalls, and the days that cover hashing.
Posts tagged
Hash tables and hash sets: how hashing works, operations and Big-O, a Python example, collisions and other pitfalls, and the days that cover hashing.
Explains the concept of hashing as a technique for mapping arbitrary-sized keys to fixed-size indices, enabling O(1) average-case lookups. Shows Python's built-in hash() function, then builds a hash table class from scratch using chaining (linked lists at each bucket) to resolve collisions. Also covers open addressing as an alternative collision strategy. Finishes with cryptographic hash functions, covering properties like pre-image resistance and the avalanche effect, and demonstrates SHA-256 hashing via Python's hashlib library.
For security reasons, please enter your password to continue.