Magic Number (programming)

Magic Number (programming)

In computer programming, the term magic number has multiple meanings. It could refer to one or more of the following:

  • A constant numerical or text value used to identify a file format or protocol; for files, see List of file signatures
  • Distinctive unique values that are unlikely to be mistaken for other meanings (e.g., Globally Unique Identifiers)
  • Unique values with unexplained meaning or multiple occurrences which could (preferably) be replaced with named constants

Read more about Magic Number (programming):  Unnamed Numerical Constants, Magic GUIDs, Magic Debug Values

Famous quotes containing the words magic and/or number:

    You become a reader because you saw and heard someone you admired enjoying the experience, someone led you to the world of books even before you could read, let you taste the magic of stories, took you to the library, and allowed you to stay up later at night to read in bed.
    Jim Trelease (20th century)

    The best number for a dinner party is two—myself and a dam’ good head waiter.
    Nubar Gulbenkian (1896–1972)