Question
Write a MATLAB script (craps.m) that plays the dice game Craps. The game is played in rounds. Each round has two phases: Come Out and
Write a MATLAB script (craps.m) that plays the dice game Craps. The game is played in rounds. Each round has two phases: Come Out and Point. A player begins a round by making one or more Come Out rolls after making their bets. A Come Out roll of 2, 3 or 12 results in the end of the round for the player and a loss of Pass Line bets. A Come Out roll of 7 or 11 (a natural) results in a win for Pass Line bets. The player continues to make Come Out rolls until a 4, 5, 6, 8, 9 or 10 is rolled and that number becomes the point. If the point number is rolled again this is a win for Pass Line bets unless a 7 is rolled in which the round ends.
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started