From locking perspective both behave the same. The only difference can be is that there can any non-null object used for a synchroized block
ie.
public myFunction (){
synchronized (anyObject) {
}
}
Now this block can be synchronized based on this object.
Where as for the case where the synchronized keyword was used , its synchronization scope depends on the calling object.
Hope this has helped you. Enjoy Coding!!!