-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathtest4d.cpp
More file actions
43 lines (39 loc) · 1.05 KB
/
test4d.cpp
File metadata and controls
43 lines (39 loc) · 1.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
//Program:3-9
//Author:James
//Date: 19/7/2019
//Decription: THis program deministrate the use of a switch stament
//THe program simply tells the user what character they entered
#include<iostream>
using namespace std;
int main()
{
char choice;
cout<<"Enter switch(A),switch(B),switch(C),switch(D),or switch (F)";
cin>> choice;
switch(choice)
{
case'A':cout<<"Excellent! you are a very good student.\n";
break;
case'B': cout<<" well done! There are stil rooms for improvement.try to get A grade.\n";
break;
case 'c':cout<<" well done! There are stil rooms for improvement.try to get A grade.\n";
break;
case'D':cout<<"You passed! You should aim for better result.\n";
break;
case'F':cout<<"You faild! you must study harder!.\n";
break;
default: cout<<"You did not enter A,B,orC!\n";
}
return 0;
}
//Program: 3-9.
//Author: james.
//Date: 19/7/2019.
// Decription: This Program deministrate the uses of switch statement
#include<iostream>
using namespace std;
int main()
{
char choice;
return 0;
}