Which methods are utilized to control the access to an object in multi-threaded programming?
Show answerHide answer
Correct answer: (B) Synchronized methods
Explanation
Synchronization is the capability to control the access of multiple threads to shared resources. Without it, one Java thread could modify a shared variable while another thread is using or updating the same variable; synchronized methods prevent this.