which one is the best practice using synchronization method
or synchronization block



which one is the best practice using synchronization method or synchronization block..

Answer / prajakta lakhe

synchronization block is the best practice to implement
synchronization. It allows us to synchronize the method whose
source code we dont know. and also this style helps us to
synchronize the particular block of code,where multiple
processes or threads can use a single resource at a time.

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More Programming Languages AllOther Interview Questions

what is session state?

0 Answers   HCL,


In OB52 , How to define two open posting period, Like only 5 and 8 posting should be open.. should not open 6 and 7..period..

0 Answers  


how to write the fallowing code in java? 1 4 9 16 25 36 49 64 81 100

1 Answers  


why main() method should not return any value

2 Answers   Accenture,


cobol is execution r not without jcl

0 Answers   IBM,






Write a program to find factorial of a number using functions

0 Answers   Peerless,


What is a dialog based program

1 Answers  


1.group by clause explain along with an example 

1 Answers   Parexel,


Given a arbitrary pointer to an element in a singly linked list?what is the time complexity for its deletion .

1 Answers   Hughes,


i want to insert textbox value to sql db. i have only one text box but store four values. ple give any one give sample code in asp.net c#..

1 Answers   Concentrix,


What is the output of the following x = "abcdef" i = "a" for i in x: print(i), a) no output b) i i i i i i … c) a a a a a a … d) a b c d e f

0 Answers   Peerless,


Question:Why is mapping required? Computer 'Paging' & 'Segmentation'. Question:Give the disadvantages of Havander's Strategies. Question: What do you mean by Belady's Anomaly. - Describe with example. Question: Discuss the various function of OS. Question: Give a brief discussion on schedulers & Dispatchers with respect to process management.

0 Answers  


Categories