Hashing is used for fast lookup: passwords (store hash, not plain text), compilers (variable names), caches, and dictionaries. Do not assume order; use a BST if you need sorted data. Summary: O(1) average, O(n) worst case, chaining or probing for collisions, load factor under 0.7.
Security: Sites do not store "password123". They store the hash. So even if data is stolen, the password is not exposed.
e.g. hash("password123") = "a8f3...92"
Variables: Finding a variable name in code must be very fast. Compilers use a hash table (symbol table) for this.
Cache: Store recent results by key. Hash table gives fast lookup so we can get cached data in O(1).
Applications
Pitfall
Hashing does not keep data in sorted order. If you need to list items in order or do range queries, use a BST, not a hash table.
Cheat sheet