Software Design/Shorten variable's name to the first letter of the type noun

From Wikiversity
Jump to navigation Jump to search

Checklist question:

  • If choosing to call a variable with a single letter, is it the first letter of the main noun of the variable's type, rather than generic a or x?

Example[edit | edit source]

If the type of the variable is MyEntry, call the variable e: the first letter of the noun "entry".

Related[edit | edit source]

See also[edit | edit source]