Multiple choice technology platforms and products

How can a dead thread be restarted?

  1. Thread.start()

  2. Thread.run()

  3. Thread.yield()

  4. A dead thread cannot be restarted.

Reveal answer Fill a bubble to check yourself
D Correct answer
Explanation

Once a Java thread completes its execution (exits its run() method) or is terminated, its state becomes 'TERMINATED' (dead). In JVM, you cannot restart a dead thread; attempting to call start() on it again will throw an IllegalThreadStateException.