Atom

An atom is any non-negative integer of any size. The atom is the most basic data type in Nock and Hoon.

A Hoon atom type consists of a Nock atom with two additional pieces of metadata: an aura, which is a soft type that declares if an atom is a date, a ship name, a number, etc, and an optional constant. A Hoon atom type is warm or cold based on whether or not the constant exists:

  • A Hoon atom type is warm if the constant is ~ (null), any atom is in the type.
  • A Hoon atom type is cold if the constant is [~ atom], its only legal value is the exact value of the atom.

Further Reading

Edit this page on GitHub

Last modified October 8, 2023