| Wyo VB Ch. 4 Worksheet #3 |
Name- |
Write a Select Case structure that would display the following values into the textbox named txtOutput given the following values of the Integer variable intGrade. Use proper indentation and spacing.
Write you answers here:
|
intGrade
|
txtOutput
|
| 90 and above | "You earned an A." |
| 80-89 | "You earned a B." |
| 70-79 | "You earned a C." |
| 60-69 | "You earned a D." |
| anything else | "You earned an E." |
|
intGrade
|
txtOutput
|
| 5 | "You owe nothing." |
| 4 | "You owe $1." |
| 3 | "You owe $2." |
| 2 | "You owe $3." |
| 1 | "You owe $4." |
| anything else | "You owe $5." |
Use the String variable strGrade in the problem below.
|
strGrade
|
txtOutput
|
| "A" | "Congratulations" |
| "B" | "Pretty Good" |
| "C" | "Average" |
| "D" | "Poor" |
| "E" | "Terrible" |
| anything else | "Were you absent?" |