This is what I need help with:

"Write an application to simulate the rolling of two standard six-sided dice. The application should use an object from the class Random to roll the first die and then again to roll the second. Each die can have the values of 1 to 6 and the sum of the dice can have values from 2 to 12. Use a one-dimensional array to tally the number of times each possible sum appears. The application should roll the dice 36,000 times. Display the results in a tabular format and determine if your results are reasonable".

What code would give me this?

KatWoman27
Deleted Member

art 2:

Write an application to simulate the rolling of two standard six-sided dice. The application should use an object from the class Random to roll the first die and then again to roll the second. Using a two-dimensional array to tally the actual combinations of rolls. A roll of 2 and 6 would be different than a roll of 6 and 2. The application should roll the dice 36,000 times. Display the results in a tabular format and determine if your results are reasonable.

Comments
In the space of a few minutes, you've moved from lazy to annoying - http://www.daniweb.com/forums/thread278457.html

Write a for loop from 1 to 36000. Check the Random class and use the method return a random number twicwe in the loop. Once for the fist die and second for the second die.

First create 2 dies
Then make a button called roll
When roll is clicked
For i = 0; i < 36000; i++
Call random class for numbers from 1 - 6
and save that number as the first die
Call it again and save that number as the second die


If you want the actual code check my site below

This is not a place for you to advertise for free your site. Go away!

This article has been dead for over six months. Start a new discussion instead.