King of Your Mother

I noticed something interesting while watching How I Met Your Mother today. This will spoil one episode from King of Queens and one episode of How I Met Your Mother, but I doubt anyone really cares.
“Damned Yanky” is the 16th episode of season 6 of King of Queens, airing on February 18, 2004.
“Double Date” is the 2nd episode of season 5 of How I Met Your Mother, airing on September 28, 2009.
Both of these shows are from CBS, and both have the same plot.
Marshall/Doug likes to fantasize about other women but feels guilty doing it. There’s only way he can rationalize it; in Marshall/Doug’s fantasies, Lily/Carrie always dies a tragic death. Years later in the fantasies, after an appropriate amount of grieving, Marshall/Doug goes after another woman, knowing it’s what Lily/Carrie would want. In actuality, Lily/Carrie is fine with Marshall/Doug fantasizing about other women but is pretty pissed off about being killed off in fantasies.