Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

PART I - Rewrite the following program using the SWITCH( ) statement # include <

ID: 3624549 • Letter: P

Question

PART I - Rewrite the following program using the SWITCH( ) statement
# include <iostream>
using namespace std;
int main ( )
/* Program Fruit created by __________________*/
{
char letter;
cout <<“ Welcome to _________________ Fruit Stand”;
cout <<“ Please enter in CAPS the First Letter of a fruit: ”;
cin >>letter;
if (letter = = ‘A’)
cout <<“Your fruit is an Apple or an Apricot”;
else if (letter = = ‘O’)
cout <<“Your fruit is an Orange”;
else if (letter = = ‘P’)
cout<< “Your fruit is a Plum or a Pineapple”;
else if (letter = = ‘B’)
cout <<“Your fruit is a Banana”;
else
cout <<“Sorry !! I do not know a Fruit that begins with that letter”;
system (“pause”);
return 0;
}

Explanation / Answer

#include using namespace std; int main() { char letter; cout