You have until Sunday, May 9, 11:00pm EDT to submit your solutions to Matlab Grader.
Read Die.m and diceGame.m. Notice that a Die has private properties top and sides. public getter methods are provided in the class definition. Next consider the function diceGame(); it contains two errors that you need to correct. Start by calling diceGame() with a small number of trials. Read both the error message and the code in diceGame.m! Correct the function so that it behaves as specified.
Make a copy of diceGame.m and call it diceGame2.m. Correspondingly, change the function name to be diceGame2. Now modify the function so that the first two elements of d are Dies while the third element of d is a TrickDie. All the dice should have 6 sides but you can choose the TrickDie’s other property values. Question to consider: Should d be a “simple” array or a cell array?
Try to solve this problem by making as little modification to the code as possible. If you are uncertain whether your solution is minimal, discuss with a classmate! Or ask one your discussion TA or consultants.