Menu
Home
People
Places
Arts
History
Plants & Animals
Science
Life & Culture
Technology
Reference.org
Magic number (programming)
open-in-new
In
computer programming
, a magic number is any of the following:
A unique value with unexplained meaning or multiple occurrences which could (preferably) be replaced with a named constant
A constant numerical or text value used to identify a
file format
or protocol (for files, see
List of file signatures
)
A distinctive unique value that is unlikely to be mistaken for other meanings (e.g.,
Universally Unique Identifiers
)