Content deleted Content added
m Tagging using AWB (10703) |
|||
Line 1:
{{
{{one source|date=January 2012 {{essay-like|date=January 2012}} }}
'''Index mapping''' is a [[computer science]] term (also known as a "'''trivial [[hash function]]'''") that is used to describe the mapping{{clarification needed|date=January 2012}} of [[raw data]], used directly as in [[array index]], for an [[array data structure|array]]. The technique can be most effective for mapping data with a small range{{clarification needed|date=January 2012}}. If the array encompasses all combinations of input, a range check is not required. ▼
▲'''Index mapping''' is a [[computer science]] term (also known as a "'''trivial [[hash function]]'''") that is used to describe the mapping{{
==Applicable arrays== ▼
In practice there are many examples of data exhibiting a small range of valid values all of which are suitable for processing{{clarification needed|date=January 2012}} using a trivial hash function including:▼
▲In practice there are many examples of data exhibiting a small range of valid values all of which are suitable for processing{{
* [[month]] in the year (1–12) – see [[#C example 1|C examples]] below
* [[day]] in the month (1–31)
* [[day of the week]] (1–7)
* human lifespan{{
* [[ASCII]] characters {{
* [[EBCDIC]] characters {{
==Examples==
Line 33 ⟶ 37:
*[[Multiway branch]]
*[[lookup table]]
==References==
{{Reflist}}
==External links==
*[http://ols.fedoraproject.org/GCC/Reprints-2008/sayle-reprint.pdf A Superoptimizer Analysis of Multiway Branch Code Generation] by Roger Anthony Sayle
<!-- do interwikis exist? -->▼
[[Category:Arrays]]
Line 43 ⟶ 51:
[[Category:Hashing|*]]
[[Category:Search algorithms]]
▲<!-- do interwikis exist? -->
|