Using a loop random three new dice values, use the new values and determine if there is a double pair of values or ‘n triple thrown.

C++ visual studio windows application

Question 1

DICE GAME
Do the necessary planning and write an algorithm in pseudo code for the following:

Random

values for

three dices

Display the

random

values

Sort the values of the dices in ascending order (Arrays are not to be implemented) Display the sorted dices

APM11A1 – Advanced

Programming

Ask the user to enter the number of times he/she wants to do analysis.

Using a loop random three new dice values, use the new values and determine if there is a double pair of values or ‘n triple thrown

Also determine if the three values thrown are all even digits or all odd digits.

If the three new values match the sorted values then stop the loop.

If there is no match in the N number of times specified by the user, then the user should be allowed to activate a process using a loop that will count how many times it would take to guess the three values correctly.

The number of times it took to guess the three values correctly should be displayed.

Using a loop random three new dice values, use the new values and determine if there is a double pair of values or ‘n triple thrown.
Scroll to top