As Ted recounts to his children the story of his meeting with their mother, his history with his four friends, Lily, Marshall, Barney, and Robin, unfolds.