Question

In: Statistics and Probability

Two people are playing an exciting game in which they take turns removing marbles from a...

Two people are playing an exciting game in which they take turns removing marbles from a bag. At the beginning of the game, this bag contains some red marbles and some blue marbles. The bag is transparent so at any time during the game, the players know exactly how many red and how many blue marbles are in the bag.

The players alternate taking turns. On a player’s turn, he or she must remove some marbles from the bag. The player chooses which marbles to remove, under the condition that he or she remove at least one marble and the marbles removed in a single turn are all the same color. The player to remove the last marble from the bag during his or her turn wins.

Assume that player 1 is playing the game with player 2, and player 1 makes the first move. If you were player 1, what optimal strategy could you use to play this game? Under what starting conditions would this optimal strategy guarantee a win, and why? What can you say about the outcome of the game if these starting conditions are not met?

(Hint: Try thinking of an invariant you could maintain during certain points of the game)

Solutions

Expert Solution

let's say player one start the game and pick out some of the marbles from the bag now it's chance for player to to play suppose player to takes out any number of marble from the bag of a particular colour now the strategy to win the game is to balance the number of marbles in the bag colour wise that means at any point of time there must be equal number of marbles red and blue present in the back so when the chance came back for player 12 play he must take out the number of marbles in such a way that the colours in the bag remains balanced. So at the end let's see there is X number of red marble and X number of Y marble now since we are balancing the number of marbles at every step so we must ensure that we must pick the last marble of a particular colour and leave one marble for the player to of other colour to pick up hence in this way we can ensure to win every time.

It's a standard programming problem you can also find it's solution on YouTube.


Related Solutions

Consider a game in which two players, Fred and Barney, take turns removing matchsticks from a...
Consider a game in which two players, Fred and Barney, take turns removing matchsticks from a pile. They start with 21 matchsticks, and Fred goes first. On each turn, each player may remove either one, two, or three matchsticks. The player to remove the last matchstick wins the game. (a) Suppose there are only 5 matchsticks left, and it is Fred’s turn. What move should Fred make to guarantee himself victory? Explain your reasoning. (b) Suppose there are 10 matchsticks...
Suppose two players take turns playing another version of the parlor game discussed in class on...
Suppose two players take turns playing another version of the parlor game discussed in class on Tuesday. In this version, players can say any whole number between 1 and 10. The first person to get the running total to 25 wins. Do you want to go first or second? Figure out the optimal strategy for this game. Show your work. (b) (5 points) ECN-322 only for this part: Suppose two players take turns playing another version of the parlor game...
There are 21 pennies on a table between two players. The two players take turns removing...
There are 21 pennies on a table between two players. The two players take turns removing either 1, 2 or 3 pennies at a time. The player who takes the last penny loses. Use backward induction to come up with a strategy that the player who takes the second turn in the game can use to guarantee that she wins the game.
There are 100 coins in a jar. Two players take turns removing anywhere from 1-10 coins...
There are 100 coins in a jar. Two players take turns removing anywhere from 1-10 coins from the jar. The player who empties the jar by removing the remaining coin(s) wins the game. To guarantee that you win the game, would you choose to move first or second, and what strategy would you follow?
You and a friend are playing a game. You alternate turns rolling a single die, and...
You and a friend are playing a game. You alternate turns rolling a single die, and the first person to roll a 1 or a 2 wins. Your friend goes first. a. What’s the probability that the game ends in three rolls or fewer? b. What’s the expected number of rolls? c. What’s the probability that your friend wins?
The Game of Pit is really fun because there are no turns. People shout out bids...
The Game of Pit is really fun because there are no turns. People shout out bids at random, chaotically. Here is a slightly simplified version of the game: There are four suits, Wheat, Barley, Corn and Rye, with nine cards each, 36 cards in all. There are four players. At the opening, the cards are all dealt out, nine to each player. The players hide their cards from each other’s sight. Players then start trading. In computer science terms, trading...
Two players take turns taking sticks from a pile of 16 sticks. Each player can take...
Two players take turns taking sticks from a pile of 16 sticks. Each player can take at most 3 sticks and at least 1 stick at each turn. Whoever takes the final stick wins the game. Describe in words the optimal strategy for each player. Is there a first-mover advantage in this game? Is there a second-mover advantage?
Suppose you are playing a game with a friend in which you bet ? dollars on...
Suppose you are playing a game with a friend in which you bet ? dollars on the flip of a fair coin: if the coin lands tails you lose your ? dollar bet, but if it lands heads, you get 2? dollars back (i.e., you get your ? dollars back plus you win ? dollars). Let ? = "the amount you gain or lose." (a) What is the expected return ?(?) on this game? (Give your answer in terms of...
You are playing a version of the roulette game, where the pockets are from 0 to...
You are playing a version of the roulette game, where the pockets are from 0 to 10 and even numbers are red and odd numbers are black (0 is green). You spin 3 times and add up the values you see. What is the probability that you get a total of 15 given on the first spin you spin a 2? What about a 3? Solve by simulation and analytically.
A con artist created a coin to swindle people from their money. If the people playing...
A con artist created a coin to swindle people from their money. If the people playing against the con artist gets heads, they win. A police officer is guessing whether the person is a con artist or not. After playing 100 times (assume this is large enough), the policeman wins 40 times. a) Construct a hypothesis test of your choice and argue whether the coin toss game is fair for the policeman (fair meaning p=0.5). Choose a significance level of...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT