Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Problem 174. Roll the Dice!

Created by @bmtran

Description

Return two random integers between 1 and 6, inclusive, to simulate rolling 2 dice.

Example

   [x1,x2] = rollDice();
   x1 = 5;
   x2 = 2;

Tags

Problem Group

Solution Statistics

879 correct solutions 1096 incorrect solutions
Last solution submitted on Sep 27, 2014

Problem Comments

Solution Comments