need to create the following program for c++ class. prompt the user to enter a number between 1 and 10.

Question # 00246519 Posted By: kimwood Updated on: 04/10/2016 04:21 PM Due on: 05/10/2016
Subject Computer Science Topic General Computer Science Tutorials:
Question
Dot Image

need to create the following program for c++ class.

1. prompt the user to enter a number between 1 and 10.

2. if the user does notenter a number within this range , ask the user again.

3. If the number entered is within this range, multiple the number times 2 and print the results.

4. Update the number to be this new product, and repeat the multiplying by 2 and printing (on a new line) until the product exceeds 100.

5. You should use a while loop and an if statement (for validating input) in your program.


//For example

Please enter a number between 1 and 10: 13

Please enter a number between 1 and 10: 6

12

24

48

96

192

Dot Image
Tutorials for this Question
  1. Tutorial # 00241757 Posted By: kimwood Posted on: 04/10/2016 04:21 PM
    Puchased By: 2
    Tutorial Preview
    The solution of need to create the following program for c++ class. prompt the user to enter a number between 1 and 10....
    Attachments
    soln.zip.ZIP (18.96 KB)

Great! We have found the solution of this question!

Whatsapp Lisa