Write a user input program that simulates a game of a rolling pair of dice. You can create/simulate rolling one die by choosing one of the integers values of 1, 2, 3, 4, 5, or 6 at randomly. If the number that the user chooses is equal to the number on the dice after it is rolled, user wins the game. As a hint use Math.random Which will perform the computation to select a random integer between 1 and 6.

Q&A Education