While Loops: Condition-Based Repetition
For loop į count-based įįįÆįįįŗ while loop į condition-based įį«į Condition true įį¼į įŗįįį½į±į· code į run įį¼į®įø unknown iterations, user input validation įįᯠscenarios įį½į±įį¾į¬ į”įįÆį¶įøįį»į¬įøįį«įįįŗį
šÆ įįįŗ įįįŗįį°įįį·įŗ į”įį¬įį»į¬įø
įį® lesson įį¾į¬ įįįŗ įįįŗįį°įįį·įŗ į”įį¬įį»į¬įø:
- While loop įįįÆįᬠįį¬įį²į įįįŗį”įį« įįÆį¶įøįįįį²
- While loop syntax įį²į· į”įįÆįįŗįįÆįįŗįįÆį¶
- While vs For loops - įįįŗį”įį»įįįŗ įį¬įįÆį¶įøįįįį²
- Do-While loop - į”įįįŗįøįįÆį¶įø įį įŗįį¼įįįŗ run įįįį·įŗ loop
- Infinite loops - įį¬įį¼į±į¬įį·įŗ įį¼į įŗįį²į įįįŗįįᯠįį¾į±į¬įįŗįįįį²
- Loop control statements (break & continue)
- Input validation įį²į· menu systems
- Real-world practical examples
š While Loop įįįÆįᬠįį¬įį²?
While loop įįįÆįᬠcondition true įį¼į įŗįįį½į±į· code block įįᯠįįįŗįį«įįįŗįį« execute įįÆįįŗįį²į· loop įį įŗįį»įįÆįøįį«į For loop įįᯠiterations į”įį±į”įį½įįŗ įįį įᬠįįįįÆįį°įø - condition false įį¼į įŗįį²į·į”įį run įį±įįįŗį
įį±į·į įįŗįįįį¾į¬ į„įįį¬įį»į¬įø:
- įįįÆįøįį½į¬įį±įįį½į±į· į”įįįŗįį¾į¬ įį±įį« (condition: įįįÆįøįį½į¬įį±įį¬)
- įįįŗįø įį¾įįŗįøįį±įįį½į±į· įį±į¬įįŗįøįį« (condition: įįįŗįøįį¾įįŗįøįį¬)
- Password įį¾į¬įøįį±įįį½į±į· įįįŗįį±įøįį« (condition: password įį¾įįŗ/įįį¾įįŗ)
- Balance įįįÆį¶įį±į¬įįŗįįį½į±į· įį½į±įįÆįįŗįįįÆį· įįįį°įø (condition: balance check)
į”į²į·įį®įįᯠscenarios įį½į±įį¾į¬ while loop į perfect!
For vs While - į”įįį įį¼į¬įøįį¬įøįį»įįŗ
| Aspect | For Loop | While Loop |
|---|---|---|
| į”įįÆį¶įøįį¼įÆįįįŗ | Iterations įįįį»įįŗįį²į·į”įį« | Condition į”įį±į«įŗ įį°įįįŗįį²į·į”įį« |
| Structure | for (init; condition; increment) | while (condition) |
| Best for | Arrays, counting, known iterations | User input, validation, unknown iterations |
| Example | Print 1 to 100 | Keep asking until password correct |
š¹ Basic While Loop Syntax
While loop įį²į· basic structure:
while (condition) {
// condition į true įį¼į
įŗįįį½į±į· run įįįŗ
statements;
// condition įįᯠupdate įįÆįįŗįįįÆį· įįį±į·įį«įį²į·!
}
į”įį±įøįį¼į®įøįį²į· į”įį»įįŗįį»į¬įø:
- Condition check: Loop body run įį® condition įįᯠį į įŗįįįŗ (pre-check)
- Update variable: Loop body įį²įį¾į¬ condition įįᯠupdate įįÆįįŗįįįįŗ (infinite loop įį¼į įŗįį¾į¬ įįįÆįįŗįįįŗ)
- Zero iterations: Initial condition į false įįįÆįįįŗ įį įŗįį¼įįįŗįį¾ į run įį°įø
- Boolean condition: Condition į boolean expression įį¼į įŗįįįįŗ (true/false)
Flow Chart
1. Check condition ā true?
āā Yes: Execute loop body
ā ā
ā Update variables
ā ā
ā Go back to step 1
ā
āā No: Exit loop, continue program
š¹ Simple Example: Count to 10
While loop įį²į· 1 įįį± 10 į”įį įį±įį½įįŗįį¼įįŗįø:
public class WhileCount {
public static void main(String[] args) {
int i = 1; // Initialize
while (i <= 10) { // Condition
System.out.println(i);
i++; // Update (į”įį±įøįį¼į®įø!)
}
System.out.println("Done!");
}
}
1 2 3 4 5 6 7 8 9 10 Done!
For loop įį²į· įį¾įįÆįįŗįøįį¾įįŗįįįŗ:
// While loop
int i = 1;
while (i <= 10) {
System.out.println(i);
i++;
}
// For loop (same result)
for (int i = 1; i <= 10; i++) {
System.out.println(i);
}
// For loop į įįįÆįį¼į®įø clean įįįÆįį¼į
įŗįįįŗ known iterations į”įį½įįŗ!
š¹ Input Validation - While Loop įį²į· į”įįŗį”į¬įø!
User į valid input įįįį·įŗįįį»į¾ įįįŗįį±įøįįįÆį· while loop į perfect:
Example 1: Password Validation
import java.util.Scanner;
public class PasswordCheck {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String correctPassword = "java123";
String userInput = "";
int attempts = 0;
int maxAttempts = 3;
System.out.println("=== Password Login System ===");
while (!userInput.equals(correctPassword) && attempts < maxAttempts) {
System.out.print("Enter password: ");
userInput = scanner.nextLine();
attempts++;
if (!userInput.equals(correctPassword)) {
int remaining = maxAttempts - attempts;
if (remaining > 0) {
System.out.println("ā Wrong password! " + remaining + " attempts left.");
} else {
System.out.println("ā Account locked! Too many failed attempts.");
}
}
}
if (userInput.equals(correctPassword)) {
System.out.println("ā Login successful! Welcome!");
}
scanner.close();
}
}
=== Password Login System === Enter password: abc123 ā Wrong password! 2 attempts left. Enter password: test ā Wrong password! 1 attempts left. Enter password: java123 ā Login successful! Welcome!
Example 2: Age Validation
import java.util.Scanner;
public class AgeValidation {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int age = -1; // Invalid initial value
System.out.println("Enter your age (1-120):");
while (age < 1 || age > 120) {
System.out.print("Age: ");
if (scanner.hasNextInt()) {
age = scanner.nextInt();
if (age < 1 || age > 120) {
System.out.println("Invalid age! Please enter between 1 and 120.");
}
} else {
System.out.println("Please enter a valid number!");
scanner.next(); // Clear invalid input
}
}
System.out.println("Thank you! Your age: " + age);
scanner.close();
}
}
š¹ Menu-Driven Programs
Menu systems įį¾į¬ while loop į į”įįįŗįø įįÆį¶įøįįįŗ - user į exit įįį½į±įøįįį»įįŗįø įįįŗįį«įįįŗįį« menu įį¼įį±įįįŗ:
import java.util.Scanner;
public class CalculatorMenu {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int choice = 0;
while (choice != 5) {
System.out.println("\n=== Simple Calculator ===");
System.out.println("1. Addition");
System.out.println("2. Subtraction");
System.out.println("3. Multiplication");
System.out.println("4. Division");
System.out.println("5. Exit");
System.out.print("Enter choice (1-5): ");
choice = scanner.nextInt();
if (choice >= 1 && choice <= 4) {
System.out.print("Enter first number: ");
double num1 = scanner.nextDouble();
System.out.print("Enter second number: ");
double num2 = scanner.nextDouble();
double result = 0;
switch (choice) {
case 1:
result = num1 + num2;
System.out.println("Result: " + num1 + " + " + num2 + " = " + result);
break;
case 2:
result = num1 - num2;
System.out.println("Result: " + num1 + " - " + num2 + " = " + result);
break;
case 3:
result = num1 * num2;
System.out.println("Result: " + num1 + " Ć " + num2 + " = " + result);
break;
case 4:
if (num2 != 0) {
result = num1 / num2;
System.out.println("Result: " + num1 + " Ć· " + num2 + " = " + result);
} else {
System.out.println("Error: Cannot divide by zero!");
}
break;
}
} else if (choice == 5) {
System.out.println("Thank you for using calculator! Goodbye!");
} else {
System.out.println("Invalid choice! Please select 1-5.");
}
}
scanner.close();
}
}
=== Simple Calculator === 1. Addition 2. Subtraction 3. Multiplication 4. Division 5. Exit Enter choice (1-5): 1 Enter first number: 10 Enter second number: 5 Result: 10.0 + 5.0 = 15.0 === Simple Calculator === 1. Addition ... Enter choice (1-5): 5 Thank you for using calculator! Goodbye!
š¹ Do-While Loop
Do-while loop į while loop įį²į· įįįŗįįįŗį įį«įį±įįį·įŗ condition įįᯠį”įįÆį¶įøįį¾į¬ į į įŗįįįŗį įįįÆįįįÆįį¬į į”įįįŗįøįįÆį¶įø įį įŗįį¼įįįŗ run įįįŗ!
do {
// Code įįᯠį”įįįŗ run įįįŗ
statements;
} while (condition); // įį±į¬įįŗįį¾ condition į
į
įŗįįįŗ
While vs Do-While:
- While: Condition į”įįįŗį į įŗ ā true įį¼į įŗįį¾ run (0 or more times)
- Do-While: į”įįįŗ run ā įį±į¬įįŗ condition į į įŗ (1 or more times)
Example: Menu (Must Show At Least Once)
import java.util.Scanner;
public class DoWhileMenu {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String response;
do {
System.out.println("\n=== Welcome to Our Service ===");
System.out.println("We're here to help you!");
System.out.println("Have a great day!");
System.out.print("\nDo you want to see this again? (yes/no): ");
response = scanner.nextLine().toLowerCase();
} while (response.equals("yes"));
System.out.println("Goodbye!");
scanner.close();
}
}
Comparison Example
// While loop
int x = 10;
while (x < 5) {
System.out.println("This never prints!"); // įį¬įį¾ įįį½įįŗįį°įø
}
// Do-While loop
int y = 10;
do {
System.out.println("This prints once!"); // įį
įŗįį¼įįįŗ įį½įįŗįįįŗ
} while (y < 5);
š¹ Infinite Loops - į”įį¹įįį¬įįŗ!
Infinite loop įįįÆįᬠcondition į įįįŗįį±į¬į·įį¾ false įįį¼į įŗįįįÆį· loop į į”įįÆį¶įøįįį¾į run įį±įį²į· į”įį¼į±į”įį±įį«:
ā Common Infinite Loop Mistakes
// Mistake 1: Forgot to update
int i = 1;
while (i <= 10) {
System.out.println(i);
// i++ įįį·įŗįįįÆį· įį±į·įį½į¬įøįįįŗ!
}
// Mistake 2: Wrong update direction
int j = 1;
while (j <= 10) {
System.out.println(j);
j--; // Decreasing instead of increasing!
}
// Mistake 3: Always true condition
while (true) {
System.out.println("Forever!");
// No break statement!
}
// Mistake 4: Wrong comparison
int count = 0;
while (count != 10) {
System.out.println(count);
count += 2; // 0,2,4,6,8,10,12... įįįŗįį±į¬į·įį¾ 10 įįį°įį°įø!
}
ā How to Avoid Infinite Loops
- Always update: Loop variable įįᯠloop body įį²įį¾į¬ update įįÆįįŗįį«
- Check direction: Increment/decrement į condition įį²į· įį®įįįįŗ
- Use break: Intentional infinite loop įį¾į¬ break condition įįį·įŗįį«
- Test carefully: Small values įį²į· test įįÆįįŗįį« (100 į”į į¬įø 5)
- Add counter: Safety counter įįį·įŗįį¼į®įø maximum iterations limit įįÆįįŗįį«
Intentional Infinite Loop (With Break)
import java.util.Scanner;
public class ServerSimulation {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
// Server į įįįįŗįįįÆį· command įįįįį»į¾ run įį±įįįŗ
while (true) {
System.out.print("Server> ");
String command = scanner.nextLine();
if (command.equals("exit")) {
System.out.println("Shutting down server...");
break; // Exit the infinite loop
}
System.out.println("Processing: " + command);
}
scanner.close();
}
}
š¹ Loop Control: Break & Continue
Break Statement
Loop įįį± įį»įįŗįį»įįŗįø įį½įįŗįįįÆį·:
// Example: Find first even number
int[] numbers = {1, 3, 5, 7, 8, 9, 11};
int i = 0;
while (i < numbers.length) {
if (numbers[i] % 2 == 0) {
System.out.println("First even number: " + numbers[i]);
break; // Found it, exit loop
}
i++;
}
// Output: First even number: 8
Continue Statement
Current iteration įįᯠskip įįÆįįŗįį¼į®įø next iteration įį½į¬įøįįįÆį·:
// Example: Print only odd numbers
int i = 1;
while (i <= 10) {
if (i % 2 == 0) {
i++;
continue; // Skip even numbers
}
System.out.println(i); // Only odd numbers print
i++;
}
// Output: 1, 3, 5, 7, 9
Break vs Continue:
- break: Loop įįį± įįÆį¶įøįįį½įįŗįį½į¬įøįįįŗ
- continue: Current iteration įįᯠskip įįÆįįŗįį¼į®įø next iteration įįᯠįįįŗįįÆįįŗįįįŗ
š» Complete Example: Number Guessing Game
While loop, break, continue į”į¬įøįįÆį¶įø įį±į«įįŗįøį įįŗįį¬įøįį²į· complete game:
import java.util.Scanner;
import java.util.Random;
public class NumberGuessingGame {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
Random random = new Random();
System.out.println("=== Number Guessing Game ===");
System.out.println("I'm thinking of a number between 1 and 100.");
int targetNumber = random.nextInt(100) + 1;
int attempts = 0;
int maxAttempts = 7;
boolean hasWon = false;
while (attempts < maxAttempts) {
int remaining = maxAttempts - attempts;
System.out.println("\nAttempts remaining: " + remaining);
System.out.print("Enter your guess: ");
// Input validation
if (!scanner.hasNextInt()) {
System.out.println("ā Invalid input! Please enter a number.");
scanner.next(); // Clear bad input
continue; // Skip this iteration
}
int guess = scanner.nextInt();
attempts++;
// Check if out of range
if (guess < 1 || guess > 100) {
System.out.println("ā Please guess between 1 and 100!");
attempts--; // Don't count this attempt
continue;
}
// Check the guess
if (guess == targetNumber) {
hasWon = true;
System.out.println("\nš Congratulations! You won!");
System.out.println("The number was: " + targetNumber);
System.out.println("You guessed it in " + attempts + " attempts!");
break; // Exit the loop
} else if (guess < targetNumber) {
int difference = targetNumber - guess;
if (difference <= 5) {
System.out.println("š„ Very close! Too low!");
} else if (difference <= 15) {
System.out.println("š Too low!");
} else {
System.out.println("ā¬ļø Way too low!");
}
} else {
int difference = guess - targetNumber;
if (difference <= 5) {
System.out.println("š„ Very close! Too high!");
} else if (difference <= 15) {
System.out.println("š Too high!");
} else {
System.out.println("ā¬ļø Way too high!");
}
}
}
if (!hasWon) {
System.out.println("\nš¢ Game Over! You ran out of attempts.");
System.out.println("The number was: " + targetNumber);
}
System.out.println("\nThanks for playing!");
scanner.close();
}
}
=== Number Guessing Game === I'm thinking of a number between 1 and 100. Attempts remaining: 7 Enter your guess: 50 š Too high! Attempts remaining: 6 Enter your guess: 25 š Too low! Attempts remaining: 5 Enter your guess: 37 š„ Very close! Too low! Attempts remaining: 4 Enter your guess: 40 š Congratulations! You won! The number was: 40 You guessed it in 4 attempts! Thanks for playing!
š» Advanced Example: ATM Banking System
Real-world scenario - ATM machine simulation:
import java.util.Scanner;
public class ATMSystem {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
// Account data
String accountName = "Aung Aung";
int pin = 1234;
double balance = 50000;
boolean isAuthenticated = false;
int loginAttempts = 0;
int maxLoginAttempts = 3;
System.out.println("=== Welcome to A Coder Bank ATM ===");
// PIN verification
while (!isAuthenticated && loginAttempts < maxLoginAttempts) {
System.out.print("Enter your PIN: ");
int userPin = scanner.nextInt();
loginAttempts++;
if (userPin == pin) {
isAuthenticated = true;
System.out.println("ā Login successful!");
} else {
int remaining = maxLoginAttempts - loginAttempts;
if (remaining > 0) {
System.out.println("ā Incorrect PIN! " + remaining + " attempts left.");
} else {
System.out.println("ā Card blocked! Too many failed attempts.");
}
}
}
// Main menu (if authenticated)
if (isAuthenticated) {
int choice = 0;
while (choice != 4) {
System.out.println("\n=== Main Menu ===");
System.out.println("Account: " + accountName);
System.out.println("1. Check Balance");
System.out.println("2. Deposit");
System.out.println("3. Withdraw");
System.out.println("4. Exit");
System.out.print("Enter choice (1-4): ");
choice = scanner.nextInt();
switch (choice) {
case 1:
// Check balance
System.out.println("\n=== Balance Inquiry ===");
System.out.println("Current Balance: " + balance + " Kyats");
break;
case 2:
// Deposit
System.out.println("\n=== Deposit ===");
System.out.print("Enter amount to deposit: ");
double depositAmount = scanner.nextDouble();
if (depositAmount > 0 && depositAmount <= 1000000) {
balance += depositAmount;
System.out.println("ā Deposit successful!");
System.out.println("Deposited: " + depositAmount + " Kyats");
System.out.println("New Balance: " + balance + " Kyats");
} else {
System.out.println("ā Invalid amount! (Max: 1,000,000 Kyats)");
}
break;
case 3:
// Withdraw
System.out.println("\n=== Withdrawal ===");
System.out.print("Enter amount to withdraw: ");
double withdrawAmount = scanner.nextDouble();
if (withdrawAmount <= 0) {
System.out.println("ā Invalid amount!");
} else if (withdrawAmount > balance) {
System.out.println("ā Insufficient balance!");
System.out.println("Available: " + balance + " Kyats");
} else if (withdrawAmount > 500000) {
System.out.println("ā Daily withdrawal limit: 500,000 Kyats");
} else {
balance -= withdrawAmount;
System.out.println("ā Withdrawal successful!");
System.out.println("Withdrawn: " + withdrawAmount + " Kyats");
System.out.println("Remaining Balance: " + balance + " Kyats");
// Dispense money simulation
System.out.println("\nDispensing money...");
int[] notes = {50000, 10000, 5000, 1000};
double remaining = withdrawAmount;
for (int note : notes) {
if (remaining >= note) {
int count = (int)(remaining / note);
System.out.println(note + " Kyats Ć " + count);
remaining = remaining % note;
}
}
}
break;
case 4:
System.out.println("\n=== Thank You ===");
System.out.println("Please take your card.");
System.out.println("Have a nice day!");
break;
default:
System.out.println("ā Invalid choice! Please select 1-4.");
}
}
}
scanner.close();
}
}
=== Welcome to A Coder Bank ATM === Enter your PIN: 1234 ā Login successful! === Main Menu === Account: Aung Aung 1. Check Balance 2. Deposit 3. Withdraw 4. Exit Enter choice (1-4): 3 === Withdrawal === Enter amount to withdraw: 75000 ā Withdrawal successful! Withdrawn: 75000.0 Kyats Remaining Balance: -25000.0 Kyats Dispensing money... 50000 Kyats Ć 1 10000 Kyats Ć 2 5000 Kyats Ć 1 === Main Menu === ...
š¹ Common While Loop Patterns
Pattern 1: Sentinel-Controlled Loop
Special value (sentinel) įį±į¬įįŗįį²į·į”įį run:
Scanner scanner = new Scanner(System.in);
int num;
System.out.println("Enter numbers (0 to stop):");
while ((num = scanner.nextInt()) != 0) {
System.out.println("You entered: " + num);
}
System.out.println("Done!");
Pattern 2: Flag-Controlled Loop
Boolean flag įįÆį¶įøįį¼į®įø control:
boolean keepRunning = true;
while (keepRunning) {
// Do something
if (someCondition) {
keepRunning = false; // Stop the loop
}
}
Pattern 3: Counter-Controlled (Known Max)
Maximum iterations įį¾įįį²į· validation:
int attempts = 0;
int maxAttempts = 5;
boolean success = false;
while (!success && attempts < maxAttempts) {
// Try something
attempts++;
if (successfulOperation) {
success = true;
}
}
šÆ į”įįį įį¾įįŗįį¬įøįįįį·įŗ į”įį»įįŗįį»į¬įø
- While loop: Condition true įį¼į įŗįįį½į±į· run įįįŗ (0 or more times)
- Do-while loop: į”įįįŗ run, įį±į¬įįŗ condition į į įŗ (1 or more times)
- Use while when: Iterations įįį, condition-based, user input validation
- Use for when: Iterations įį, counting, arrays
- Always update: Loop variable įįᯠupdate įįÆįįŗįįįÆį· įįį±į·įį«įį²į· (infinite loop įį¼į įŗįįįŗ)
- Break: Loop įįį± įįÆį¶įøįįį½įįŗįįįÆį·
- Continue: Current iteration skip įįÆįįŗįįįÆį·
- Input validation: While loop į perfect (valid input įįįįį»į¾ įįįŗįį±įø)
- Menu systems: Do-while įįÆį¶įøįįįŗ menu įįᯠį”įįįŗįøįįÆį¶įø įį įŗįį¼įįįŗ įį¼įįįŗ
- Infinite loops: Testing įį²į· safety counters įįÆį¶įøįį¼į®įø įį¾į±į¬įįŗįį«
- Boolean flags: Complex conditions į”įį½įįŗ boolean variables įįÆį¶įøįį«
āļø Practice Exercise
Exercise: Factorial Calculator
While loop įįÆį¶įøįį¼į®įø factorial įį½įįŗįį²į· program įį±įøįį«:
- User įįį± positive number įį įŗįᯠinput įį°įį«
- Factorial įį½įįŗįį« (5! = 5 Ć 4 Ć 3 Ć 2 Ć 1 = 120)
- Input validation įįÆįįŗįį« (negative numbers reject)
- User į "exit" įįįÆį· įįįÆįįŗįį¾ įįįŗįį«
Example:
Enter a number (or 'exit' to quit): 5
5! = 120
Enter a number (or 'exit' to quit): 6
6! = 720
Enter a number (or 'exit' to quit): exit
Goodbye!
š” Solution įį¼įį·įŗįįįŗ (Try įįÆįįŗįį¼į®įøįį¾ įį¼įį·įŗįį«)
import java.util.Scanner;
public class FactorialCalculator {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
String input = "";
System.out.println("=== Factorial Calculator ===");
while (!input.equals("exit")) {
System.out.print("Enter a number (or 'exit' to quit): ");
input = scanner.nextLine();
if (input.equals("exit")) {
System.out.println("Goodbye!");
break;
}
try {
int n = Integer.parseInt(input);
if (n < 0) {
System.out.println("Error: Please enter a positive number!");
continue;
}
long factorial = 1;
int i = 1;
while (i <= n) {
factorial *= i;
i++;
}
System.out.println(n + "! = " + factorial);
} catch (NumberFormatException e) {
System.out.println("Error: Invalid input!");
}
System.out.println();
}
scanner.close();
}
}
š Quick Quiz
Question 1: įį® while loop į įįįŗįį¾į įŗįį¼įįįŗ run įįį²?
int x = 5;
while (x > 3) {
System.out.println(x);
x--;
}
Question 2: Do-while loop įį²į· while loop įį²į· į”įįį įį¼į¬įøįį¬įøįį»įįŗį įį¬įį²?
Question 3: įįįŗ scenario įį¾į¬ while loop į for loop įįįŗ įįįÆįį±į¬įįŗįøįį²?
š Congratulations!
Module 3: Control Flow įį¼į®įøįį«įį¼į®!
įįįŗ įįįŗįį°įį¼į®įøįį¬įø į”įį¬įį»į¬įø:
- ā Lesson 9: If-Else Statements
- ā Lesson 10: Switch Statements
- ā Lesson 11: For Loops
- ā Lesson 12: While Loops
Course Progress: 50% Complete!
12 of 24 lessons finished!
Next: Module 4 - Methods š