What does the `Thread.sleep()` method do in Java?
`Thread.sleep()` is used to stop a thread from executing until the operating system decides to give it back the CPU.
Thatâ€™s incorrect. `Thread.sleep()` only pauses the thread for a specified time, it doesnâ€™t rely on the operating system's scheduling.
Can you explain how the JVM handles the scheduling of threads during `sleep()`?