On a summer day when the speed of sound is 340 m/s, a ship sounds a whistle. The echo from the shore is heard on the ship 4 seconds later. What is the distance from the ship to the shore?