synchronized : how it worked | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

synchronized : how it worked

Can explain me about synchronized in java and what's it and how it work??? Tell me about lock and unlocked read and write in class ...

3rd Jul 2018, 10:52 AM
Zahra
Zahra - avatar
1 Answer
+ 2
You use synchronized annotation to prevent using same variable when parallel processing is in place. Java locked variable for write when is used with another thread.
5th Jul 2018, 9:10 PM
Majstr