Synchronized Methods and Synchronized Blocks

If you declare a method to be synchronized, then the entire body of the method becomes synchronized; if you use the synchronized block, however, then you can surround just the “critical section” of the method in the synchronized block, while leaving the rest of the method out of the block.   If the entire method ...