Failure can lead to pain but ultimately results in success through perseverance. This is illustrated by the story of Robert Bruce, king of Scotland, who was defeated multiple times trying to free his country from the English. While hiding in a cave, he saw a spider fail nine times at climbing its web before succeeding on the tenth try. Inspired by the spider's perseverance, Bruce gathered his army again and ultimately defeated the English, winning freedom for Scotland. The moral is that patience and perseverance can overcome any challenge, and failure should be viewed as a stepping stone to success.