← Java Foundations

Week 3 — Decisions, Methods, and Contracts

Apr 13 – Apr 17  ·  6 lessons  ·  Labs 5, 6, 7

Objectives

  • Trace nested and chained conditionals by hand
  • Combine conditions with && and ||; use short-circuit safely
  • Write a static method with parameters and a return
  • Document and enforce a precondition with IllegalArgumentException
  • Use switch for discrete dispatch; recognize fall-through
  • Use ternary for two-outcome value selection

This Week

Quiz
If/else tracing — practice set
Lab 5
Chat With a Bot — due Wed 4/15 at 11pm
Lab 6
Eligibility Checker — due Fri 4/17 at 11pm
Lab 7
Choose Your Path — due Mon 4/20 at 11pm