Updated

First his North Carolina players gave Roy Williams a tough, hard-fought, milestone victory.

Then they surprised their coach with a specially made gift to help him commemorate the occasion.

As soon as the Tar Heels got into the locker room after beating gritty Villanova 78-71 in the second round of the NCAA tournament Friday night, they gave Williams a jersey with the number 700 emblazoned on the front. It was his 700th career win, a plateau he had been downplaying all week but a moment his players had said they all wanted to be a part of.

"It was special because Coach didn't even know we had the jersey for him," said P.J. Hairston, who led North Carolina with 23 points. "He wasn't expecting it at all. He is proud, but he wasn't even thinking about the 700."

Now he's surely thinking about what comes next.

North Carolina's win set up a dream matchup Sunday in the third round of the South Regional between the eighth-seeded Tar Heels (25-10) and top-seeded Kansas, where Williams coached for 15 years and rang up 418 wins.

The Jayhawks (30-5) struggled to put away scrappy Western Kentucky in a 64-57 victory Friday night.

Kansas fans have been jamming the Sprint Center in downtown Kansas City, about 30 minutes from the Jayhawks' campus. Now, they get the game they've been waiting for.

By beating Villanova, Williams extended his NCAA record of consecutive tournament appearances with at least one win to 21.

"I love the mental toughness of our team the last eight or nine minutes," he said.

The never-say-die Wildcats (20-14) have plenty to be proud of as well.

They erased a 20-point deficit that North Carolina built in the first half and then nearly climbed out of a nine-point hole in the final minutes after the Tar Heels hit three consecutive 3-pointers and once again appeared to take control.

"I'm proud of this team. I'm proud of their effort," Villanova coach Jay Wright said. "They're tough guys. They've got faith in what we do."

Picking on a season-long weakness for the ninth-seeded Wildcats, North Carolina shot 11 of 21 from 3-point range while getting outrebounded 37-28.

JayVaughn Pinkston had 20 points and Darrun Hilliard scored 18 for Villanova.

After UNC took a seemingly comfortable 65-56 lead on Hairston's 3-pointer and James Michael McAdoo's jumper, Ryan Arcidiacono answered with Villanova's second 3, cutting the lead to 65-59. But Marcus Paige dropped in a short jumper that put the Tar Heels on top 67-59 before a media timeout with 3:03 to go.

A pair of foul shots by Arcidiacono, James Bell's 3-pointer and Pinkston's two free throws sliced the lead to 67-66. Paige then drilled a 3 and Hairston completed a three-point play a little while later for a 76-68 lead with 42 seconds left.

"I thought earlier in the game it was all happy and smooth and the ball was going in the basket," Williams said. "Then all of a sudden they started competing a little harder than we did."

Earlier, trying to protect a precarious 54-50 lead over the plucky Wildcats, North Carolina went to its strongest weapon and unleashed 3-pointers on three straight possessions by Hairston, Reggie Bullock and Hairston again.

Shooting from long range, the Tar Heels were openly exploiting a season-long weakness for Villanova, which had struggled with perimeter defense.

"We worked really hard on trying to prevent them from getting 3s," Wright said. "They do a great job. They know you're trying to stop their 3s."

Paige had 14 points and Bullock added 15 for UNC.

Mouphtaou Yarou scored 17 points and Arcidiacono had 10 for Villanova.

A 15-0 run midway through the first half led to a 32-12 North Carolina lead and Williams appeared poised to comfortably cruise to victory No. 700. A jumper by McAdoo gave North Carolina its biggest lead with 7 minutes to go in the half.

But after going without a field goal from the 10:56 mark to 5:16 showing on the game clock, the Wildcats regrouped, pounced on some sudden sloppiness by North Carolina and closed out the half on a 14-3 spree to go into halftime trailing only 37-29.

Then, opening the second half on an 11-3 spurt, they finally caught up when Hilliard's layup tied it 40-all at the 16:04 mark.

"We just couldn't make a shot," Hairston said. "We took some crazy shots, we rushed some shots, we turned the ball over and at the same time Villanova was coming down and getting chip-ins and easy two-point plays."

Hilliard's bucket and Pinkston's putback gave Villanova a 44-42 lead, its first since it was 4-3. But at the 12:06 mark, Bullock's third 3-pointer gave North Carolina a 47-45 advantage.

Paige, Hairston and McDonald all hit 3-pointers while the Wildcats were committing five turnovers during North Carolina's first-half run. After Leslie McDonald took a pass from Bullock and moved in for a layup, Hairston scored on an underhand scoop and McDonald drilled a 3 to put North Carolina on top 28-11.

Two free throws by McAdoo made it 30-11, then Pinkston and Arcidiacono hit free throws before Pinkston dropped in a jumper to end the Wildcats' field goal drought.

Pinkston got open for a 12-footer and Hilliard followed with another short jumper, making it 37-23. After a Tar Heels turnover, Tony Chennault kept the spree alive with another bucket.