/
Naming Accuracy
Naming Accuracy
Variable names must be accurate to successfully communicate understanding to readers. If a variable name doesn’t accurately reflect what the variable is supposed to represent, something might be communicated to a reader, but it won’t be what the code is doing or intended to do.
Inaccurate variable names can communicate no actual understanding or wrong understanding. Neither is good, so aim to make your names accurate. Articulate what the variable represents in words (either out loud, in your head, or written down), and then use those words as the basis for a good variable name.
The following sections contain more specific tips on what to do or not do when it comes to variable naming accuracy:
, multiple selections available,
Related content
Name Length & Specificity
Name Length & Specificity
More like this
The Importance of Variable Naming
The Importance of Variable Naming
More like this
Giving Names to the Unnamed
Giving Names to the Unnamed
More like this
Problem Domain Naming
Problem Domain Naming
Read with this
Make Names Specific Enough to Distinguish Between Similar Variables [VS6]
Make Names Specific Enough to Distinguish Between Similar Variables [VS6]
More like this
Avoid Overly Short Names [VS1]
Avoid Overly Short Names [VS1]
More like this