Page 1 of 1

[HD Pg 0, Sec. 12.1.0 - using-the-math-class]

Posted: Sat Apr 27, 2024 3:33 am
by Katzor
Book: OCFA Java Foundations Exam Fundamentals 1Z0-811: Study guide for Oracle Certified Foundations Associate, Java Certification
Build: 1st Jan 2021 Build 1.1
Observe that, unlike with the Math.random() method, you need to first create an instance of the Random class and then call an appropriate getXXX method to get a random int, long, float, or double value.
Besides the nor args getInt method, it also has getInt(int bound) method ...
From the context it is rather clear what is meant but I could not find any getXXX methods in the Java API docs of 1.8 and 11. in my opinion get should be replaced with next here.

Great book, I hope one day I will get all the way to OCP Java certification. I am grateful you provide us with this material for little money! :thumbup:

Re: [HD Pg 0, Sec. 12.1.0 - using-the-math-class]

Posted: Sat Apr 27, 2024 10:46 am
by admin
You are right. It should be nextXXX methods.

All the best for your preparation.

Re: [HD Pg 0, Sec. 12.1.0 - using-the-math-class]

Posted: Thu Nov 07, 2024 3:58 am
by sabrina23
In your study experience with this book, have you encountered any other places where method names or details differ from the official Java API documentation? If so, how did you handle those differences in understanding?

Re: [HD Pg 0, Sec. 12.1.0 - using-the-math-class]

Posted: Fri Nov 08, 2024 7:21 am
by admin
Don't worry, you will not be surprised in the exam if you go through the book.