Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Avoid the use of numerical values or "magic numbers" in code when possible. Appropriately Rather, use appropriately named symbolic constants clarify the intent of the programmer. In addition, if a specific number needs to be changed reassigning a symbolic value constant once is more efficient and less error prone than replacing every instance of specific number in the code.

...

When declaring immutable symbolic values, such as ADULT_AGE it is best to use const or enum as explained in DCL00-A. Declare immutable values using const or enum.

...