From Khalil Zachary’s vantage point, Brett Bennett’s desperation three-point attempt at the buzzer seemed destined to fall through the hoop.

Zachary had played a key role in shutting down North Shore’s Tyler Rieger, who scored just two of his 16 points after halftime, but the two free throws he had missed seconds earlier could have unraveled Glen Cove’s comeback. So as Bennett’s shot sailed through the air, Zachary held his breath.

“I actually thought he was going to make it,” Zachary said, “but I felt a sigh of relief when he missed that three pointer.”

The Glen Cove gym burst into shouts and cheers of celebration. The Big Red defeated its Nassau A-III rival, 64-63, on Wednesday night.

Zachary, who matched teammate Corey Dinkins with a game-high 20 points, chased Rieger around the court all game. Rieger beat Zachary several times in the first half, especially in the second quarter, when he scored 10 points and helped North Shore take a 31-24 lead at halftime. But during the break, Glen Cove coach Pete Falen challenged Zachary and his teammates to take Rieger out of the equation.

“We just tried to preach defense the whole second half,” said Zachary, who also had eight rebounds, “and we executed on it.”

advertisement | advertise on newsday

As the 6-2 Zachary denied the 6-3 Rieger of clean catches and forced him into tough shots, Glen Cove (6-3) began turning defense into offense. Kevin Ernest (16 points) jumped passing lanes and picked pockets for five second-half steals, which the Big Red converted into 10 points.

“That was big,” Dinkins said. “Kevin’s a great defensive player.”

After North Shore’s Harry Laderer buried a three-pointer with 4:49 left, Glen Cove trailed 54-46. Ernest had two steals in the next 1:29 to help cut the gap to 55-52. With 2:10 left, he corralled a ball poked loose by Neri Romero, raced down the court and missed a layup, which Zachary tipped in to make it 60-59.

Then Ernest followed a pass to Rieger on the left wing. He and Zachary trapped Rieger, forcing a scramble that ended with Dinkins gathering a loose ball and scoring the go-ahead layup with 1:39 remaining.

Glen Cove led the rest of the game, and can clinch a playoff spot with a win over Bethpage on Friday.

“It starts off with defense,” Ernest said. “We weren’t taking it offensively. We weren’t really executing. Defense is what wins games.”