1. Math
  2. Statistics And Probability
  3. problem 10 below is a working matlab program to simulate...

Question: problem 10 below is a working matlab program to simulate...

Question details

Problem 10 Below is a working Matlab program to simulate many games of craps. The program plays 10,000 games, and determines Prob _win. Code this program and play 10,000 games 10 separate times. Make a table of P(win craps) with your ten results. How can you use this table to determine the accuracy of your game simulation % simulate the odds of winning at craps % CES 5010 clear num-10000 %number of simulations x=cei 1( rand (num ,4)*6); win-o try help rand, and help ceil, to see whats happening for i=1 : num summ1 x (i,1)x (i,2) win win+1 else win win+l; end end end Prob winwin/num disp(lProbability of winningnum2str (Prob win)])
Solution by an expert tutor
Blurred Solution
This question has been solved
Subscribe to see this solution