Question: In c + + plz Problem 3 - Filename: GameBase Write a program that plays a math game using different bases. The game is simple:

In c++plz Problem 3- Filename: GameBase
Write a program that plays a math game using different bases. The game is simple: it has two steps:
convert and repeat. Given a number, convert it to base 10 from the smallest base it could possibly be
read in until it can no longer be converted into a smaller number.
Input from the keyboard a positive integer in the range [1,1000000000] to simulate the game
with. Assume proper input. Output to the screen first the original number in base ten, and then one per
line each reduction. After the number can no longer be reduced, print it. Finally, the program should ask
if the user wants to run the program again (Check case). Refer to the sample output below.
Sample Run:
Enter integer: 457
51 base 4
31 base 6
13 base 4
7 base 4
7
Run Again (YN) : Y
Enter integer: 718347628
718347628 base 10
310570550 base 9
52621672 base 8
11215802 base 8
5443364 base 9
666299 base 7
666299
Run Again (YN) : n
In c + + plz Problem 3 - Filename: GameBase Write

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Programming Questions!