Chapter 5. Flow control
Exam objectives covered in this chapter |
What you need to know |
---|---|
[3.3] Create if and if/else and ternary constructs. | How to use if, if-else, if-else-if-else, and nested if constructs. The differences between using these if constructs with and without curly braces {}. How to use a ternary construct. How it compares with if and if-else constructs. |
[3.4] Use a switch statement. | How to use a switch statement by passing the correct type of arguments to the switch statement and case and default labels. The change in the code flow when break and return statements are used in the switch statement. |
[5.1] Create and use while loops. | How to use the while loop, including determining when to apply the while loop. |
Get OCA Java SE 8 Programmer I Certification Guide now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.