This programming exercise is based on Programming Challenge 11 from the Gaddis text. You are to write the simulation for a game played by two or more players. In the game, each player starts out with some number of points. Each player takes a turn rolling a dice. The amount generated by the dice is subtracted from the players points. The first player with exactly one point remaining wins. If a players remaining points minus the amount generated by the dice results in a value less than one, then the amount is added to the players points.
At the start of the game, prompt the user for these values:
- the number of points to start with
- the number of players
Once these values are provided by the user, the simulation runs to completion, playing itself until one of the players wins (i.e., gets a score of one). This is a simulation. It is not supposed to be a game played interactively by the user.
As the simulation proceeds, output lines of text showing the status after each players turn, indicating:
- what player is playing (e.g., player 0, player 1, etc.)
- what value was generated by rolling the dice
- points remaining for that player
- when one of the players wins, announce the winner

![[Solved] CS143-Assignment 2 First to One Simulation](https://assignmentchef.com/wp-content/uploads/2022/08/downloadzip.jpg)

![[Solved] CS143 Project 5](https://assignmentchef.com/wp-content/uploads/2022/08/downloadzip-1200x1200.jpg)
Reviews
There are no reviews yet.