Jump to content

Lookup table

From Simple English Wikipedia, the free encyclopedia
Revision as of 14:32, 11 October 2013 by Bryce combs (talk | changes) (I just changed a little error in grammar - preposition usage.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

In computer science, a lookup table is a data structure, usually an array or associative array, used to replace a runtime computation (calculation) with a simple array indexing operation. The main purpose is in saving run time since retrieving a value from memory is often faster than undergoing a time consuming computation (see Space-time tradeoff). Lookup tables are also used to validate input values by matching against a list of valid (or invalid) items in an array.