I should create a Java program called FindThatNumber.java. The program should generate 10 random integers between 1 and 100 (inclusive) using Math.pow( ) and then store them sequentially in an array. The program should then ask the user to enter a single integer. If the integer is in the array just entered, the program should respond "Bingo!"; otherwise, the program should respond "Sorry". The program should continue running until the user enters -999 to quit. (Hint: The code (int) (100 * Math.random( ) + 1) creates the required random number.)

Ok -- this is what you should do:

Create a Java program called FindThatNumber.java. The program should generate 10 random integers between 1 and 100 (inclusive) using Math.pow( ) and then store them sequentially in an array. The program should then ask the user to enter a single integer. If the integer is in the array just entered, the program should respond "Bingo!"; otherwise, the program should respond "Sorry". The program should continue running until the user enters -999 to quit. (Hint: The code (int) (100 * Math.random( ) + 1) creates the required random number.)

Any questions ;) ?

hmmm...nice 1!...T_T

in case you're too stupid to get the message yet: DO YOUR OWN HOMEWORK!

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.