he Dice game of “Pig” can be played with the following rules.
- Roll two six-sided dice. Add the face values together.
- Choose whether to roll the dice again or pass the dice to your opponent.
- If you pass, then you get to bank any points earned on your turn. Those points become permanent. If you roll again, then add your result to your previous score, but you run the risk of losing all points earned since your opponent had rolled.
- Continue to roll as much as you want. However, once a “1” comes up on either die, your score is reduced to 0, leaving you only with points that you have previously "banked." Furthermore, you must pass the dice to your opponent.
The first person to 100 points is the winner.
When a player rolls two dice, the possible outcomes are as follows:
Die #2 Roll | |||||||
Roll a 1 | Roll a 2 | Roll a 3 | Roll a 4 | Roll a 5 | Roll a 6 | ||
Die #1 Roll | Roll a 1 | 0 | 0 | 0 | 0 | 0 | 0 |
Roll a 2 | 0 | 4 | 5 | 6 | 7 | 8 | |
Roll a 3 | 0 | 5 | 6 | 7 | 8 | 9 | |
Roll a 4 | 0 | 6 | 7 | 8 | 9 | 10 | |
Roll a 5 | 0 | 7 | 8 | 9 | 10 | 11 | |
Roll a 6 | 0 | 8 | 9 | 10 | 11 | 12 |
You can see that a player gets 0 points if they roll a 1 on either die. Otherwise their score comes from adding the results of the two dice. There are 25 ways to "successfully" roll the dice and 11 ways to "unsuccessfully" roll the dice, where "success" is not rolling a 1 on either die.
Single Roll
When we take the mean of the 25 successful rolls we get 8. We will assume that on a successful roll, the player earns 8 points.
P(success) = 2536
P(failure)=1136
Value(success) = 8
Value(failure) = 0
What is the expected value for a single roll? 11 (Round to four decimal places)
Two Rolls
If we chose to pass the dice, then we would bank those points. If we chose to keep rolling, then in order to be successful we would need to roll no 1's twice. However, we would expect to get twice as many points IF we were to roll successfully. This would give us:
P(success) = (2536)2
P(failure) = 1-(2536)2
Value(success) = 16
Value(failure) = 0
What is the expected value for rolling twice? (Round to four decimal places)
More Rolls
As you can see, if we chose to roll even more times, then we could calculate the probabilities and values in a similar way. If we were to roll n times, then we have:
P(success) = (2536)�
P(failure) = 1-(2536)�
Value(success) = 8⋅�
Value(failure) = 0
What would the expected value be for:
Three rolls? (Round to four decimal places)
Four rolls? (Round to four decimal places)
Five rolls? (Round to four decimal places)
Strategy
Having looked at the five different strategies, which would you choose?
- Roll once before passing
- Roll twice before passing
- Roll three times before passing
- Roll four times before passing
- Roll five times before passing
Why would you choose this strategy?
Expected values for different strategies in the Pig dice game, is given by the formula for EV i.e.
Expected Value = (probability of success * value of success) + (probability of failure * value of failure)
Here "success" implies not rolling a 1 on any of the dice and "failure" implies rolling at least one 1 on the dice.
Single Roll case:
P(success) = 25/36
P(failure) = 11/36
Value(success) = 8
Value(failure) = 0
Expected Value = (25/36 * 8) + (11/36 * 0) = 200/36 = 5.56
Two Rolls case:
If we choose to roll twice, then two successful rolls needed to earn points, which means not rolling a 1 on any of the dice in both rolls. The probability of this happening is:
P(success) = (25/36)^2 = 625/1296
P(failure) = 1 - (25/36)^2 = 671/1296
Value(success) = 16
Value(failure) = 0
Expected Value = (625/1296 * 16) + (671/1296 * 0) = 12500/1296 = 9.63
Trending nowThis is a popular solution!
Step by stepSolved in 3 steps
Why is the strategy of rolling twice before passing the dice should be chosen? explain in detail.
Why is the strategy of rolling twice before passing the dice should be chosen? explain in detail.
- TYPEWRITTEN ONLY PLEASE UPVOTE. DOWNVOTE FOR HANDWRITTEN. DO NOT ANSWER IF YOU ALREADY ANSWERED THIS. THE BIG NUMBER IN THE SIDE IS FOR NUMBERING.arrow_forward2) scrooge.py Scrooge McDuck is letting you into his vault full of pennies, nickels, dimes and quarters. He will let you play the following game: you can pick 8 coins at random, and if they sum to at least a dollar, you win, and can keep your money! But if you lose, you don't get to keep the money, AND have to pay Scrooge a dollar. (Each coin you pick is equally likely to be a penny, nickel, dime, or quarter.) Your job: using a simulation, estimate 1. the probability that you win (meaning your coins sum to more than a dollar), and 2. if you play this game over and over, the average amount you will win (where the amount you win in a game could be negative). Here is a bit more direction: you should simulate 100,000 plays of this game. Each simulated play should involve picking 8 different random numbers - each one should be .01, .05, .10, or .25, with each value equally likely - which represent the 8 coins being chosen; these should be summed each time. As you proceed through these…arrow_forwardAlert -Don't submit AI generated answer and i need unique response only if I see plagiarism then I'll reduce rating for sure.arrow_forward
- In the Dice Roll game, the player begins with a score of 1000. The player is prompted for the numberof points to risk and a second prompt asks the player to choose either high or low. The player rollstwo dice and the outcome is compared to the player’s choice of high or low. If the dice total is between2 and 6 inclusive, then it is considered “low”. A total between 8 and 12 inclusive is “high”. A total of7 is neither high nor low, and the player loses the points at risk. If the player had called correctly, thepoints at risk are doubled and added to the total points. For a wrong call, the player loses the points atrisk. Create a DiceRollGame application that uses a DRPlayer object based on this specification. TheDRPlayer object should have two Die member variables that represent the dice. The Die class shoulduse a random number generator to determine the outcome in a roll() method. Application outputshould look similar to:arrow_forwardQ2: A mercury thermometer having a time constant of 0.1 min is placed temperature bath at 100°F and allowed to come to equilibrium with the bath. At time t= 0, the temperature of the bath begins to vary sinusoidally about its average temperature of 100°F with an amplitude of 2°F If the frequency of oscillation is 10/π cycles/min, What is the phase lag? In terms of the symbols used T = 0.1 <0 120 f = 10 元 s=100 x(t) = 100+ 2 sin(wt)) يسيفر نظارت دقت السائل SLOWarrow_forwardIn the Dice Roll game, the player begins with a score of 1000. The player is prompted for the numberof points to risk and a second prompt asks the player to choose either high or low. The player rollstwo dice and the outcome is compared to the player’s choice of high or low. If the dice total is between2 and 6 inclusive, then it is considered “low”. A total between 8 and 12 inclusive is “high”. A total of7 is neither high nor low, and the player loses the points at risk. If the player had called correctly, thepoints at risk are doubled and added to the total points. For a wrong call, the player loses the points atrisk. Create a DiceRollGame application that uses a DRPlayer object based on this specification. TheDRPlayer object should have two Die member variables that represent the dice. The Die class shoulduse a random number generator to determine the outcome in a roll() method. Application outputshould look similar to:arrow_forward
- Can u solve this ?arrow_forwardAn argument is expressed in English below. Rhys will go to the beach. If Rhys is excited; then Rhys will go to the beach. Rhys is excited. Variable names are assigned to each English phrase as follows: p: Rhys is excited •q: Rhys will go to the beach Is the argument valid? If valid, then indicate which rule is used for the argument. If invalid, then give truth assignments to the variables that prove the argument is invalid. Pick 4. Check Nextarrow_forward● Simulate the game (this will require using while and if statements as we learned in class) by using the round and trial counters you have established. ● Store a win for Player 1 or Player 2 after each round (indicate a win by a 1 and a loss by a 0). ● Store the cumulative wins of each player after each round (“P1Wins_Talley” and “P2Wins_Talley”). ● Store the overall game results in a matrix called “store_results”. Column 1 lists the round number , Column 2 lists the total number of trials in that round , Column 3 records which player won that round (1 or 2) , Column 4 records the value of Dice 1 , Column 5 records the value of Dice 2 , Column 6 records the sum of the two dice at the end of that round (which should equal the value in Column 1) I am creating a game where two players try to roll two die that equal the current round. For example, if the round is 3, the players must roll a 2 and a 1. I have written this code so far, but I am not getting the end result I need. I was hoping…arrow_forward
- Flashback to Probability: Determine the odds of rolling TWO 6-sided dice, and getting a total between the two dice that is a multiple of three.arrow_forwardA flight of stairs has 10 steps numbered 1 to 10 as shown in the figure below. i. How many ways could you climb up the set of stairs, assuming that you can skip any number of stairs with each step, but you must end on step 10 and you can only go up, never down and never remaining on the same step. ii. How many ways could you climb up the set of stairs, assuming you take exactly 4 steps. Again, your staircase climb ends on step 10. JAlthough there are different ways in which you could solve this problem, model the problem as a balls and bins problem for full credit.arrow_forwardA "mad-lib" is a fill-in-the blank game. One player writes a short story in which some words are replacedby blanks. For each word that is removed, the appropriate part of speech is noted: e.g. noun (person/-place/thing), adjective (word that describes a noun), verb (an action, e.g. eat), adverb (modifies a verb, e.g.quickly). Then, before reading the story, the story-writer asks the other player to write down a word of theappropriate part of speech for each blank without knowing the context in which it will be used. In this way,a humorous (sometimes) or non-sensical (usually) story is created a)arrow_forward
- Computer Networking: A Top-Down Approach (7th Edi...Computer EngineeringISBN:9780133594140Author:James Kurose, Keith RossPublisher:PEARSONComputer Organization and Design MIPS Edition, Fi...Computer EngineeringISBN:9780124077263Author:David A. Patterson, John L. HennessyPublisher:Elsevier ScienceNetwork+ Guide to Networks (MindTap Course List)Computer EngineeringISBN:9781337569330Author:Jill West, Tamara Dean, Jean AndrewsPublisher:Cengage Learning
- Concepts of Database ManagementComputer EngineeringISBN:9781337093422Author:Joy L. Starks, Philip J. Pratt, Mary Z. LastPublisher:Cengage LearningPrelude to ProgrammingComputer EngineeringISBN:9780133750423Author:VENIT, StewartPublisher:Pearson EducationSc Business Data Communications and Networking, T...Computer EngineeringISBN:9781119368830Author:FITZGERALDPublisher:WILEY