import java.util.*; public class ForEachExample { public static void main(String[] args) { String[] colors = {"Red", "Green", "Blue"}; int day = 3; String dayName = switch (day) { case 1 -> "Monday"; case 2 -> "Tuesday"; case 3 -> "Wednesday"; default -> "Invalid day"; }; System.out.println(dayName); } }