I really do not understand the answer.
Q 5 of 19 (Concurrency)- enthuware.ocpjp.v11.2.1235
You want to execute a task that returns a result without blocking. Which of the following types from java.util.concurrent package will be required to achieve this?
Valid answers: ExecutorService, Executors, Callable, Future.
How Runnable is a bad answer?
Is Future get() doesn't block?
enthuware.ocpjp.v11.2.1235
Moderator: admin
-
- Posts: 1
- Joined: Thu Apr 21, 2022 7:59 am
- Contact:
-
- Site Admin
- Posts: 10065
- Joined: Fri Sep 10, 2010 9:26 pm
- Contact:
Re: enthuware.ocpjp.v11.2.1235
1. Runnable is not in java.util.concurrent package
2. Its run method returns void.
3. Callable's call method returns immediately.
2. Its run method returns void.
3. Callable's call method returns immediately.
If you like our products and services, please help us by posting your review here.
Who is online
Users browsing this forum: Google [Bot] and 99 guests