what is mean by synchronization?

Answer Posted / uma

synchronized means that in a multiple threaded
environment,a synchronized object does not let two threads
access the same time.this means that one thread cant be
reading while another updates it.the second thread will
instead wait until the first is done.the overhead is
speed,but the advantage is guaranteed consistency of data..

Is This Answer Correct ?    4 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is difference between Heap and Stack Memory?

536


What is main in java?

515


What does || mean in vectors?

478


Why is logger singleton?

564


Difference between association, composition and aggregation?

563






What is %d in printf?

534


What is generics in java interview questions?

541


Why is string builder not thread safe?

592


Can you pass by reference in java?

528


Is a class an object?

582


What is void in java?

593


Can main() method in java can return any data?

646


Can we write method inside a method in java?

526


What is the difference between instanceof and isinstance?

568


What are the two environment variables that must be set in order to run any java programs?

531