Solved:
//Roll the die 36,000 times
for ( int roll = 1; roll <=36000; roll++ )
{
int die1 = 1 + randomNumbers.nextInt ( 6 );
int die2 = 1 + randomNumbers.nextInt ( 6 );
int...
Type: Posts; User: SnarkKnuckle
Solved:
//Roll the die 36,000 times
for ( int roll = 1; roll <=36000; roll++ )
{
int die1 = 1 + randomNumbers.nextInt ( 6 );
int die2 = 1 + randomNumbers.nextInt ( 6 );
int...
I think I may have a little more information but now I'm getting a dice1 cannot be initialized and I do not believe I am totalling up the two correctly to store them back into the array.
I have coded a dice rolling simulation to roll a single die 36,000 times, store the data in the array and display how many times the face value landed. My question is what do I need to do to change...
Yes, it's in a gui arrangement, theres a JTextField that populates on the right hand side that should pull from the arry of PLayers 1-5 depending on how many were selected after hitting the...
Thanks that helped with a lot. Now if I can just get these variable, arrays and that text field on the right side to keep score that would be fantastic
I'm unsure about what to do with this section of code, errors are on lines 368 - 388, it's underlined in red using Eclipse and says, pointDie*JLabel1 (* is 1-5) as it does this on all lines through...
Thanks for the array info, I think I see how I"ll utilize those. However before I do any ideas on how to correct how the points are being passed?
I've programmed a dice game for pig which utilizes a single die. The points are suppose to accumulate during your turn unless you hit a 1 and they are zeroed out and nothing added to your total or...
The order in which I had them seem to differ from your println code and I wasn't getting good results then, but anyways I changed the code, learned from my mistakes and this one is solved. Thanks
Thank you, I know I had tried the quotes, but also looks like I had the "+" signs jacked up too.
When trying to tab the following code I keep getting: Syntax error on token "Invalid Character", ( expected, that's the error when mousing over the \t underlined, and the "x" error on the left ( I"m...
Thanks for the replies ;)
As I was coding this and finally got it working, yes I am new with Java programming, and programming in general, I was wondering if theres not a better way of coding this, especially with the...
I'm only like two days into my first Java...well first programming class ever and here's my issue, or the issue I created for myself rather.
For starters it's a basic BMI program. I have the...