reformat
This commit is contained in:
parent
316cf8c1d6
commit
e5aef8679f
159 changed files with 1141 additions and 1100 deletions
|
|
@ -0,0 +1,12 @@
|
|||
|
||||
|
||||
## What are three ways a thread **voluntarily** relinquishes the processor?
|
||||
|
||||
---
|
||||
|
||||
🙋
|
||||
|
||||
1. **`Thread.yield()`**: Explicitly giving up the processor.
|
||||
2. **`Thread.sleep()`**: Ceasing execution for a specific time.
|
||||
3. **`Object.wait()`**: Waiting for a notification from another thread.
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue