answersLogoWhite

0

Any name that is not a reserved word can be a legal variable, function or type name. All names must be alphanumeric, but they cannot begin with a digit. The C++ standard recommends that all user-defined names be written entirely in lower case with underscores for spaces. Some programmers prefer 'camel case' (such as PrintObject and MaxNumber), which was a popular convention amongst the Pascal programming community, however print_object and max_number are the C++ conventions. Names in all caps are typically reserved for macro definitions (which is effectively a separate language from C++ itself), while names with leading underscores should generally be avoided as this convention is utilised extensively within the standard library.

User Avatar

Wiki User

11y ago

What else can I help you with?