Page 1 of 1

About Question enthuware.ocpjp.ii.v11.2.3317 :

Posted: Sat Nov 14, 2020 7:12 pm
by dfigueira
Regarding this sentence in the explanation:
DoubleUnaryOperator is a function that accepts a Double value and returns a Double and so can be used here.
"(...)DoubleUnaryOperator is a function that accepts a double and returns a double (...)"
Since we are assigning this lambda expression to a DoubleFunction<DoubleUnaryOperator>, it implies that we are trying to using this lambda expression to implement a DoubleFunction that converts a Double into a DoubleUnaryOperator.
"(...)DoubleFunction that converts a double into a DoubleUnaryOperator(...)"

Re: About Question enthuware.ocpjp.ii.v11.2.3317 :

Posted: Sun Nov 15, 2020 2:44 am
by admin
Correct. Fixed.
thank you for your feedback!

Re: About Question enthuware.ocpjp.ii.v11.2.3317 :

Posted: Tue Nov 24, 2020 11:31 am
by sirtomash
Besides technical issues this text contains letter typo:
Now, in this question we are using a DoubleStream and so, its map method expects a an operation that can accept a Double value and onvert it to some other Double value. (Note that the resulting stream, therefore, will also be of type DoubleStream).