Lab Exercise of Switch Statement
- Get a copy of the
- Compile and run this C++ program.
Try the following input values -10, 0, 101, 100, 40, 50, 60, 70, 80, 90, 85, and 98.
- Write a program named switch.cpp
using switch statement to do the following:
- Read a letter grade
- Print out the corresponding mark interval and message
- For example, if grade is 'A', the program should print out "Your mark is greater than or equal to 95." and "Great work.".
Copyright: Department of Computer Science, University of Regina.