Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Please make the program useable in Visual Studio 1. Your program must use one or more C++ classes. Classes can have functions. However, outside a
Please make the program useable in Visual Studio
1. Your program must use one or more C++ classes. Classes can have functions. However, outside a class only the main function may be created. All variables must be local. Any C++ classes you create must not have any public data members. You may not use the rand() function to create your program. You may use uniform_int_distribution, however. Create a game using C++ object-oriented programming. The game is played as follows. The player throws two discs on a two-dimensional grid. The grid is 10 by 10. The player wins if the discs overlap. The discs must be thrown randomly. Assume when a disc is thrown, its center is always on integer coordinates. For example, a center may be at (2, 4), where 2 is the x-coordinate and 4 is the y-coordinate. Your program prompts the user to specify the radius of the first disc and then the radius of the second disc. The discs are represented by objects. Then your program prompts the user to throw the discs. Finally, the program displays the radii of the two discs, their center coordinates, and whether the user won the game or notStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started