nextInt() is a method of the Random class, in your code you've not declared 'generator' as a variable of that class. So your code should be something like
Random generator = new Random(); int a = generator.nextInt(); int b = generator.nextInt(); There's more details here http://www.javapractices.com/topic/TopicAction.do?Id=62 --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/javaprogrammingwithpassion?hl=en -~----------~----~----~----~------~----~------~--~---
