Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

write a program that will allow the user to play either two rounds or four rounds of the popular dice game. This game program must

write a program that will allow the user to play either two rounds or four rounds of the popular dice game. This game program must ask the user to determine whether to play this game with two rounds or four rounds before rolling the dice.

The rules of craps are as follows:

A player rolls two dice.

  • If the sum of dice is either 2, 4 or 7 on the first throw, the player wins.
  • If the sum is 9 on the first throw, the player loses.
  • If the sum of the two dice does not belongs to the winning numbers or the losing number, then it becomes the players target number on the first throw.
  • To win, the player must continue rolling the dice until a roll matches to this target number.

Hello, I tried writing this code but the results I get don't give me the 2 rounds and 4 rounds . i was hoping you could help me write this in PHYTHON? thank you.

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Advances In Databases And Information Systems 22nd European Conference Adbis 2018 Budapest Hungary September 2 5 2018 Proceedings Lncs 11019

Authors: Andras Benczur ,Bernhard Thalheim ,Tomas Horvath

1st Edition

3319983970, 978-3319983974

More Books

Students also viewed these Databases questions

Question

State the importance of control

Answered: 1 week ago

Question

What are the functions of top management?

Answered: 1 week ago

Question

Bring out the limitations of planning.

Answered: 1 week ago

Question

Why should a business be socially responsible?

Answered: 1 week ago