60 622
Assignments Done
97,8%
Successfully Done
In April 2018

Answer to Question #19782 in C++ for zoya arshi

Question #19782
W.A.P in C++ to display a menu,
1. Print number of odd numbers and even numbers inside a range accepted from the user.
2. print no.of prime numbers within an accepted range.
3. Print this pattern.
****
***
**
*
4. Exit.
Expert's answer
#include<iostream>
#include<string>
using namespace std;

int main ()
{
int choice;
do {
& cout << "1. Print number of odd numbers and even numbers inside a range accepted from the user." << endl;
& cout << "2. Print no.of prime numbers within an accepted range." << endl;
& cout << "3. Print this pattern. \n****\n***\n**\n*" << endl;
& cout << "4. Exit." << endl;
& cin >> choice;
& switch(choice){

& case 1: break;

& case 2 : break;

& case 3 : break;

& case 4 : return 0;

& }
}
while (choice != 4);
system("pause");
return 0;

}


Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Comments

No comments. Be first!

Leave a comment

Ask Your question

Submit
Privacy policy Terms and Conditions