Question:

Which method is used to pause the execution of a thread for a specific period?

Show Hint

Look for the timed pause method. Thread.sleep(ms) suspends a thread for a given duration.
Updated On: Jul 2, 2026
  • wait()
  • stop()
  • sleep()
  • pause()
Show Solution
collegedunia
Verified By Collegedunia

The Correct Option is C

Solution and Explanation

Step 1: The task is to halt a thread for a fixed amount of time, then let it continue on its own.

Step 2: Thread.sleep(milliseconds) does exactly this. It suspends the current thread for the given duration.

Step 3: wait() releases a lock and waits for notify, stop() is a deprecated kill method, and pause() is not a standard Thread method.

Step 4: The correct choice is sleep(). Answer is (C).
Was this answer helpful?
0
0