Alternatively, you can prompt the user in the beginning for the number of dice they want made. You can then set the size of the array according to what they wanted. That way you don't have to worry...
Type: Posts; User: aussiemcgr
Alternatively, you can prompt the user in the beginning for the number of dice they want made. You can then set the size of the array according to what they wanted. That way you don't have to worry...
An infinite number of dice? Yes it is possible, but it would not very practical as you could never print them all out (since there are an infinite amount.
To create an infinite number of dice (or...
I will show you how I did my arrays since it doesn't actually give you the logic for creating the dice.
//Create an array of dice. This array holds 20 dice
int[] dieType = new int[20];
//Loop...
There really isn't an elegant way for this part. Since you know the number of die that will be printed, I would have an array of ints (representing what type of die each die should be going from left...
This is one of those things that I really wish I could do for you. Sounds like fun. But I won't since you seem to be doing this for your own personal interests.
I'll give you some hints on how to...