Question: 2 . Write a switch statement that will examine the value of an integer variable called flag and print one of the following messages, depending

2. Write a switch statement that will examine the value of an integer variable called "flag" and print one of the following messages, depending on the value assigned to "flag".
a. HOT, if flag has value 1
b. LUKE WARM, if flag has value 2
c. COLD, if flag has value 3
d. OUT OF RANGE, if flag has any other value
2 . Write a switch statement that will examine

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!