What are the two ways you can synchronize a block of code?

Answer Posted / guest

bu using thread in your main program

Is This Answer Correct ?    2 Yes 16 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is package protected in java?

738


Is it possible to cast an int value into a byte variable? What would happen if the value of int is larger than byte?

741


what do you understand by synchronization? Or what is synchronization and why is it important? Or describe synchronization in respect to multithreading? Or what is synchronization? : Java thread

715


How many types of the indexof method are there for strings?

730


What are runtime exceptions?

902


What is the default size of load factor in hashing based collection?

814


Difference between class#getinstance() and new operator ?

891


What is the escape character in java?

738


Is c better than java?

740


Explain about oops concepts.

871


Explain 5 features introduced in jdk 1.7?

814


Can we make main() thread as daemon?

846


What do you mean by inner class in java? Explain

817


What is token in java?

779


What are the problems faced by java programmers who don't use layout managers?

748