Did the sea around japan help protect them from invasion?

In the past, the sea around Japan helped to protect them from invasion. However, after the USA developed the atom bomb, the difficulty of invading Japan influenced them to drop the atom bomb.