Create a C program that prompt the user to enter hisher firs
Solution
************************Question number:16******************************************
#include <iostream> // library that contains basic input output functions
#include <string>
#include<conio.h>
using namespace std;
int main(){
string fname,lname;
cout << \"Enter First name: \"; // prompting
cin >> fname;
cout << \"Enter Last name: \";
cin >> lname;
cout<<\"Your Full name is: \"<<fname<<\" \"<<lname;
getch();
}
********************** Question 18 ******************************
#include<iostream> // In order to read or write to the standard input/output streams you need to include it
#include<conio.h>//console input and output
using namespace std;
int main()
{
char option;
char quit=\'q\';
// do while starts
do{
cout<<\"\ Taco Bell lunch Menu:\ \"<<endl;
cout<<\"1.Crunchy Taco\ 2.Crunchy Taco Supreme\ 3.Soft Taco\ 4.Soft Taco Supreme\ 5.Chicken Soft Taco\ q.QUIT\"<<endl;
// displaying menu
cin>>option;// taking option as input
switch(option){ // showing options respectively
case \'1\':
cout<<\"Crunchy Taco $2\"<<endl;
break;
case \'2\':
cout<<\"Crunchy Taco Supreme $3\"<<endl;
break;
case \'3\':
cout<<\"Soft Taco $10\"<<endl;
break;
case \'4\':
cout<<\"Soft Taco Supreme $5\"<<endl;
break;
case \'5\':
cout<<\"Chicken Soft Taco $4\"<<endl;
break;
default:
cout<<\"Enter right option\"<<endl;
}
}while(option!=quit); // while user enter \'q\'
getch();
return 0;
}
************************* CLOSE 18***************************
**************************** CLOSE***************************

