Brendan Gallagher said he didn’t know whether it was the best game he ever played, but the Canadiens rookie said it was the “funnest.”

You should know that Gallagher’s idea of fun is to stand in front of the opponents and let bigger guys whack away at him. The evidence could be seen in the cut above his lip but he was all smiles after leading the Canadiens to an improbable 6-5 shootout win over the Boston Bruins Wednesday night at the TD Garden.

Gallagher scored at 12:18 of the third period to bring the Canadiens to within a goal, at 5-4, and he was creating traffic in front when Andrei Markov atoned for a shaky night on defence by scoring the tying goal with 8.2 seconds remaining in regulation time.

And then there was the coup de grâce. After 11 players came up empty, Gallagher scored the only goal in the shootout.

“I was planning to deke, but then I saw what he was doing and I realized it wasn’t going to work and I just shot it,” the 20-year-old rookie said.

“He shows a lot of character by going to the dirty places and competing,” said Josh Gorges, the veteran defenceman who has taken Gallagher under his wing. “He gets hacked and he gets whacked and cross-checked and he’s still going to the front of the net.”

Gorges said he hasn’t seen enough of the other candidates to anoint Gallagher as the favourite in the rookie-of-the-year sweepstakes, but he said: “I don’t know if there are many rookies who have the impact he has on our team.”

Gallagher had to share the laurels with backup goaltender Peter Budaj, who was called on to play the third period. He stopped 14 of the 15 shots he faced in the third period and overtime and then was a perfect 6-for-6 in the shootout.