"How I Met Your Mother" star Neil Patrick Harris is one of the few people who didn't hate the comedy's series finale.

On the "Late Show with David Letterman" Thursday, the actor, who's now on Broadway starring in "Hedwig and the Angry Inch," explained why he thought "HIMYM" creators Carter Bays and Craig Thomas made the right call.

"It wasn't necessarily the happy ending that people were expecting, but Carter and Craig ... knew this ending years ago and had played towards that," Harris said. "I was a big proponent of it and a big fan of it."

Suffice to say not everyone was. When the staple CBS comedy wrapped after nine seasons in March, Bays and Thomas revealed a twist ending: The "Mother" fans had been waiting years to meet had died, and Ted (Josh Radnor) - the man who was telling this lengthy story to his kids - winds up back with Robin (Cobie Smulders). That was an awkward reunion for some viewers, who thought Robin was happily married off to Harris' Barney Stinson. (They ended up divorced.)

"Sometimes people's growth doesn't really mean that they grow up," Harris told Letterman, who joked that he'd sought "professional counseling" after that ending. "There are certain people who, you want them to get in a solid relationship and settle down and learn from things, and you want Barney to be the guy you can bring your mom home to, but Barney's the guy that wants to bang your mom. And so at the end of the day, it's not always meant to be that way."