Skip to content

Module 02 · Controlling Program Flow

This module covers how Java decides what runs next: conditionals, the modern switch (statements and expressions), and the loop family with break/continue. It is exam objective group 2 — small, but dense with traps around fall-through, exhaustiveness, and iteration.

Lessons

#LessonWhat it covers
01Conditionals — if / elseif/else if/else, block scope, braces, the dangling-else trap.
02The switchStatement fall-through, switch expressions (->, yield), exhaustiveness, selector types, case null.
03Loops & Branchingwhile/do-while, classic & enhanced for, labeled break/continue, iteration pitfalls.

Track your progress

Your progress0 / 3 (0%)

Module Mini-Exam

A timed, mixed quiz covering the whole module. Aim well above the real exam's 68% pass bar.

Mini-Exam

  • 8 questions
  • 15 minutes
  • 10 total points
  • Pass: 7 pts (68%)