What is the function of the Future submit(Callable task) method of the ExecutorService interface?

What is the function of the Future<T> submit(Callable<T> task) method of the ExecutorService interface?



Answer: Submits the thread for execution and returns a Future to represent the task. The get() method of the Future returns the value produced by the call() method of the Callable object


Learn More :

Multithreading and Concurrent Processing

Learn More Multiple Choice Question :