Code:`int sec = cal.get(Calendar.SECOND);`

int sec2 = sec / 3;

int sec3 = Math.round(sec2);

ok i got a number 1-20 im gunna use as a seed to generate 10,000 random numbers 1-20. i need a formula to put it through, any suggestions?

Printable View

- 01-14-2008, 04:09 AMcarlos123random numbers without random class`Code:
`int sec = cal.get(Calendar.SECOND);`

int sec2 = sec / 3;

int sec3 = Math.round(sec2);

ok i got a number 1-20 im gunna use as a seed to generate 10,000 random numbers 1-20. i need a formula to put it through, any suggestions? - 01-14-2008, 11:12 PMtim
Hello carlos123

If you don't want to use the Random class then try Math.random(). If this is not what you want then your problem is mathematical and not Java related. See this site :Pseudorandom series

Hope this helped. :p - 01-15-2008, 02:15 AMcarlos123
do you understand what i need to do?

- 01-15-2008, 08:16 AMtimQuote:

Originally Posted by**carlos123**

- 01-17-2008, 10:44 PMcarlos123
Ok, but i still need help, thanks.