Craps. The following are the rules for a pass bet in the game of craps. Roll two six-sided dice, and let x be their sum. • If x is 7 or 11, you win. • If x is 2, 3, or 12, you lose. Otherwise,...


Craps. The following are the rules for a pass bet in the game of craps. Roll two six-sided dice, and let x be their sum.


• If x is 7 or 11, you win.


• If x is 2, 3, or 12, you lose.


Otherwise, repeatedly roll the two dice until their sum is either x or 7.


• If their sum is x, you win.


• If their sum is 7, you lose.


Q:187


Write a modular program to estimate the probability of winning a pass bet. Modify your program to handle loaded dice, where the probability of a die landing on 1 is taken from the command line, the probability of landing on 6 is 1/6 minus that probability, and 2–5 are assumed equally likely. Hint: Use StdRandom. discrete().

Dec 10, 2021
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here