This style guide should apply to language-agnostic programming techniques and practices. For language-specific style, see the style guide for that specific language.
For easy of reading, use underscores between words in a variable name. There is one exception to this and that is java. See Case in the Java Code Style Guide for details.
Good
c
while(amount_read > 0)
amount_read = some_read_function(these_args);
Bad
c
while(amount_read > 0) amount_read = some_read_function(these_args);
Variable names with multiple words should be delimited with underscore characters, "_", rather than globing them together.
Variable names should start with a lower case alphabetical character.
Names of boolean types should reflect the question to which their values are true, if possible.
Class names with multiple words should be globed together and should start with a capital letter.
Format is MAJOR.MINOR.REVISION.
Return to Categories