Java Multithreading Pertanyaan dan Jawaban Wawancara
Question: Explain the concept of thread safety.Answer: Thread safety is a property that ensures that a block of code or a class can be safely executed by multiple threads concurrently without causing data corruption.Example:
|
Simpan untuk Revisi
Bookmark item ini, tandai sebagai sulit, atau masukkan ke dalam set revisi.
Masuk untuk menyimpan bookmark, pertanyaan sulit, dan set revisi.
Apakah ini membantu? Ya Tidak
Most helpful rated by users:
- What is multithreading?
- What is the purpose of the yield() method?
- What is the purpose of the sleep() method in Java?
- How do you create a thread in Java?
- Explain the difference between Thread and Runnable.