RALEIGH - North Carolina spent the last month learning how to finish strong and won four straight games as a result.
But the No. 23 Tar Heels couldn't close their final game or their regular season on a positive note, losing a 28-27 heartbreaker to rival N.C. State.
"This is the toughest loss," defensive tackle Marvin Austin said. "It could possibly be the last time I get to play them, so it's hard and demoralizing for me. I'd rather beat them than beat any other team."
The Wolfpack blocked a 38-yard field goal attempt by UNC's Casey Barth with less than five minutes to go to preserve the win.
Barth said afterward that the snap and hold were "perfect" and that he just kicked the ball too low.
But there were plenty of UNC mistakes before Barth's that cost the Tar Heels this win.
Carolina (8-4, 4-4 in the ACC), which had so often this season won despite poor offensive showings, actually amassed a season-high in total offense by the end of the third quarter.
But mental errors - including a season-high 122 penalty yards - led to enough missed opportunities to sink the Heels for the third straight season against N.C State (5-7, 2-6)
State quarterback Russell Wilson, meanwhile, was 20-for-27 passing for 259 yards and all four of the Wolfpack's touchdowns.
Both of his second-half touchdowns were long ones to Owen Spencer - a 56-yarder in the third quarter and a 38-yarder on the second play of the fourth quarter to take the lead.
"Big plays are the back-breakers," UNC coach Butch Davis said. "It keeps the momentum going in the other direction."
Early on, it looked like Carolina had all the mojo in this game.
Freshman wide receiver Jheranie Boyd had a pair of first-half touchdowns totaling 105 yards, a perfect example of the kind of demoralizing strikes the Heels were capable of against a weak State defense.
Johnny White also rushed for a 40-yard touchdown, the longest run of his career, in the second quarter.
But it was hard for the Tar Heels not to wonder just how many points they might have had if not for some crucial mistakes.
White fumbled at the goal line on UNC's second possession, costing the Heels a touchdown. On the game's opening drive, a holding call on tight end Zack Pianalto forced UNC to settle for a field goal.
Instead of 14 points, the Heels had just three.
"If we had those points, it would have been a different outcome," receiver Greg Little said.
In the second half, a personal foul on guard Alan Pelc took Carolina from being inside the State 10-yard line to settling for a 20-yard field goal.
And on the series that ended with State blocking Barth's kick, Boyd took a killer 12-yard loss on a run play instead of just getting on the ground when the play first blew up in the backfield.
Even in a season where the offense has had games in which it was completely ineffective, quarterback T.J. Yates - who led the Heels to a season-high 481 yards - said it was far more frustrating to move the ball and then fail to score because of penalties or other mistakes.
"It's a lot worse," said Yates, whose 280 passing yards were his highest total in more than two years. "If you're getting stuffed, you give credit to the defense. If we keep taking it away from ourselves, there's no one to blame but ourselves.
The UNC defense had plenty of problems of its own.
It racked up three penalties for 44 yards in a four-play sequence as part of the Wolfpack's second touchdown drive of the game, while other miscues didn't result in flags but allowed Wilson to complete big plays.
That each side of the ball had its failings in a rivalry game to end the season only made it hurt more, even though there is still a bowl game on the horizon.
"It won't be easy to forget, with them having bragging rights," UNC safety Deunta Williams said. "But we'll move on."