Question: Selection Program In this assignment you will demonstrate all three of the standard selection operations: - if , elseif, else - switch / case -

Selection Program
In this assignment you will demonstrate all three of the standard selection operations:
- if,elseif, else
- switch/case
- ternary.
This is the procedure for this assignment, follow these steps:
1. Take a single input from the user.
2. Perform some validation on the input.
3. Create an if: elseif: else block with at least 4 comparisons (more is better)
4. Report based upon the selection
5. Create a switch/case structure that mirrors the if block.
6. Report in a similar manner.
7. rite a ternary example using the same input data. (You only need to create one test, no need to report differently on all 4(or more) possible outcomes.
Selection Program In this assignment you will

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!