Multiple Choice
Which of the following will yield a pseudorandom number in the range [ -5, +5 ) given the following: Random gen = new Random( ) ;
A) gen.nextFloat( ) * 5
B) gen.nextFloat( ) * 10 - 5
C) gen.nextFloat( ) * 5 - 10
D) gen.nextInt( ) * 10 - 5
E) gen.nextInt(10) - 5
Correct Answer:

Verified
Correct Answer:
Verified
Q26: JOptionPane is a class that provides GUI<br>A)
Q27: For the program to get a name
Q28: System.out.println("123" + 4) will display the value
Q29: The advantage(s) of the Random class' pseudo-random
Q30: If two variables contain aliases of the
Q32: The Swing package<br>A) completely replaces the AWT<br>B)
Q34: Consider the following two lines of code.
Q35: Layout managers are associated with<br>A) objects<br>B) interfaces<br>C)
Q36: If you need to import not only
Q38: In Java, the symbol "=" and the