Next: , Previous: Sequences Arrays Vectors, Up: Top

7 Hash Tables

A hash table is a very fast kind of lookup table, somewhat like an alist (see Association Lists) in that it maps keys to corresponding values. It differs from an alist in these ways:

Emacs Lisp provides a general-purpose hash table data type, along with a series of functions for operating on them. Hash tables have a special printed representation, which consists of ‘#s’ followed by a list specifying the hash table properties and contents. See Creating Hash. (Note that the term “hash notation”, which refers to the initial ‘#’ character used in the printed representations of objects with no read representation, has nothing to do with the term “hash table”. See Printed Representation.)

Obarrays are also a kind of hash table, but they are a different type of object and are used only for recording interned symbols (see Creating Symbols).