September 2016
Intermediate to advanced
704 pages
18h 29m
English
Identifiers are names of packages, classes, interfaces, methods, and variables. Though identifying a valid identifier is not explicitly included in the exam objectives, there’s a good chance that you’ll encounter a question similar to the following that will require you to identify valid and invalid identifiers:
Question: Which of the following lines of code will compile successfully?
The correct answer is (a). Option (b) is incorrect because hyphens aren’t allowed in the name of a Java identifier. Underscores are allowed.
Table 2.7 contains a list of rules that will enable you to correctly define valid (and invalid) identifiers, along with some ...
Read now
Unlock full access