with Certified Solutions
A thread in Java allows multiple tasks to run concurrently.
✔✔True
The Runnable interface in Java has a method called run().
✔✔True
A thread in Java starts executing as soon as it is created.
✔✔False
The start() method is used to begin the execution of a thread.
✔✔True
The join() method allows one thread to wait for another to finish.
✔✔True
1
, A Java thread can be restarted after it has finished execution.
✔✔False
The synchronized keyword is used to prevent race conditions in multithreading.
✔✔True
Two threads can execute a synchronized method of the same object at the same time.
✔✔False
The yield() method pauses the current thread to allow other threads to execute.
✔✔True
The sleep() method immediately stops a thread permanently.
✔✔False
A daemon thread runs in the background and does not prevent the JVM from exiting.
✔✔True
2