169k views
2 votes
Based on the naming recommendations in the book, which of the following is a good identifier for a variable that will be used to hold an employee’s phone number? a. EmployeePhoneNumber b. emphonumber c. employee_phone_number d. empPhoneNum

User Zimmi
by
6.9k points

1 Answer

2 votes

Answer:

A good identifier for a variable that will be used to hold an employee’s phone number is:

a. EmployeePhoneNumber

Step-by-step explanation:

An identifier is a string that uniquely identifies or names the entity or an object. The object or entity may be a constant, variable, structure, function, etc. Identifiers can be formed from uppercase and lowercase letters, digits, and underscores. Meaningful identifiers mostly favor the use of long descriptive names like EmployeePhoneNumber. However, the other options can still be used.

User Seun Osewa
by
6.8k points