Question: Write a program in java that gets the traffic light state if it is red, yellow, or green with enumeration and switch Yellow: Caution Green:
Write a program in java that gets the traffic light state if it is red, yellow, or green with enumeration and switch
Yellow: Caution
Green: Go
Red: Stop
Otherwise tells us: Invalid Input
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
