FARMINGTON — Maranacook’s Gabe Fein, Luke Bartol and Carter McPhedran swept the top three places to lead their team to its third straight Class B Nordic state championship, and Yarmouth successfully defended its girls’ title Tuesday at Titcomb Mountain.

After going 1-2-3 in Monday’s classical race, McPhedran, Fein and Bartol were separated by 27 seconds at the start of the 5-kilometer freestyle pursuit.

As they exited the woods and entered the final stretch before the finish line, Bartol had taken the lead, with Fein and McPhedran close behind. Fein overtook his teammate before the finish line, as the three Black Bears finished just three seconds apart.

“I could not have imagined a better way to end the season, there are no words to describe it,” Bartol said.

The Maranacook trio helped each other after Bartol and Fein caught McPhedran.

“When Luke caught up to me, we would work together,” McPhedran said. “I would lead him up a hill, then he would pass me again. … It wasn’t planned, it was on the spot. It’s always the best to be competing with your teammates because you’ll push each other, but you know that at the end of the day you’re there to support each other, and that’s honestly the best feeling.”

Maranacook finished with 791 points, while Freeport was second with 768. Freeport had five skiers in the top 14, led by Martin Horne and John Giddens in fifth and sixth.

On the girls’ side, Yarmouth placed five skiers in the top 10 and took the team title by five points over Freeport, 776-771. Madeleine Marston finished fourth, and Sadie Cowles, Isabel Brennan, Natalie Teare and Jane Fulton were seventh through 10th.

“We lost a couple of girls, so we had some girls really step up and ski together as a team,” Yarmouth Coach Jay Jones said. “They skied together and pushed each other, and you can see in (Monday’s) results they were all close together. That made for a great experience, and having them ski together really helped them improve from last year.”

Lily Horne of Freeport had a 39-second headstart after her classical victory on Monday, and she maintained that margin in the pursuit, beating Eliza Skillings of Maine Coast Waldorf. Allison Greuel of Freeport was just behind Skillings in third place.

“I split the course up into three major climbs, generally, to make it easier for myself,” Horne said about skiing with a big lead. “The first climb, I tried to keep it steady, then the second climb I tried to pick it up, and then the third climb was whatever I had left. The downhill was in pretty good shape – it’s definitely not my strong suit, but I’ve been working on it this season, but it was a really fun race.”

The Class C boys’ race was won by Miguel Sanclemente of Fort Kent. Sanclemente started with just a five-second lead on Harrison Walters of the Maine School of Science and Math, but he overcame a stumble leaving the starting gate and pulled away for a 51-second margin over Madawaska’s Justin Pelletier, who nipped Waynflete’s Nicholas Werner by a tenth of a second.

Madawaska ran away with the team title, putting four skiers in the top eight.

Isabell Jandreau of Madawaska had no company in the Class C girls’ race. She entered the day with a 54-second lead, and finished with an advantage of 1:44 over Dolcie Tanguay of Maine School of Science and Math.

“It gets easier once you do it a few times but we had a lot of people on the course today, which was awesome,” Jandreau said of racing alone. “I felt pretty good. We went pretty hard yesterday, so I was definitely still feeling that. It was a good race and the conditions were awesome.”

Ashland won the girls’ team title by eight points over Waynflete and Fort Kent. Clara Sandberg and Kaitlynn Bliss finished fourth and seventh to lead Waynflete.