Search: | |||||

| ||||

Home » Forum » Java | RSS Feeds |

public class Prog3

{

public static void main (String[] args)

{

int number;

int i,random;

int userinput;

int i;

System.out.println("This program generates random

numbers between 1 and 10");

System.out.print("\nHow many random numbers to

generate(negative to stop)?");

System.out.println();

number=SavitchIn.readInt();

while (i<1 || i>10)

{

for (i=1;i<userinput;i++);

random=(int)(10*Math.random()+1);

}

i have a problem... im trying to generate randome numbers and

this code is not working for me...

am i misssing some thing?

a hint or sample code will be great thank you

Didn't find what you were looking for?
Find more on generating random numbers
Or get search suggestion and latest updates.

Related Topics:

- Help in Random Numbers
- Problem with random number in java
- HW HELP! loop, histogram, random number
- Need codes for generating random equations
- Write a script to generate a random number between 1 and 1000.
- how to generate a rondom number btween two ranges
- counting the frequency of randomly generated real number
- Converting a "Stringed" Number to a Number
- Converting a "Stringed" Number to a Number
- random images
- How to create random password for first time user in the web site
- Select random cell in list and highlight contents
- How to generate random string or character from arrays?
- Please help quick. Due tomorrow. random number array histogram!!
- Jbuilder Serial number
- Number fields in Excel being considered NULL (empty)
- Math function to determine if a number is an int
- Getting the time for the Number of records retrived
- Datagrid Display - right align numbers
- get the number of JList which is created by array
- changing the port number on JBOSS
- Formatting number
- Getting CPU Number (Id) of a computer using Applet
- How to truncate a floating number?
- convert from number (0-255) to character