1,Which of the following statements are correct? When creating a Random object,
ID: 3906026 • Letter: 1
Question
1,Which of the following statements are correct?
When creating a Random object, you have to specify the seed or use the default seed.
If two Random objects have the same seed, the sequence of the random numbers obtained from these two objects are identical.
The nextInt() method in the Random class returns the next random int value.
The nextDouble() method in the Random class returns the next random double value.2,Which of the following statements are true?
2,A default constructor is provided automatically if no constructors are explicitly declared in the class.
At least one constructor must always be defined explicitly.
Every class has a default constructor.
The default constructor is a no-arg constructor.
3,You use the ________ operator to access members of an object.
.
()
*
%
Explanation / Answer
1) All are correct 2) A default constructor is provided automatically if no constructors are explicitly declared in the class. The default constructor is a no-arg constructor. 3) .
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.