ANN ARBOR, Mich. (AP) — The ball bounced right to Charles Matthews, who dribbled once and squared up to shoot as the game clock — and more importantly, the shot clock — neared zero.

"I saw the clock when I did get the ball. I'm not sure exactly how much time, but I did know that there was time on the clock," Matthews said. "So I didn't want to just throw up a crazy shot. I wanted to still follow through with it."

Matthews used up what little time he had, then made a baseline floater at the buzzer to lift No. 5 Michigan to a 59-57 win over Minnesota on Tuesday night.

On the final possession, Iggy Brazdeikis drove to the basket and had his shot blocked by Eric Curry, but the ball bounced over to Matthews to the left of the rim. His shot went high in the air and dropped through with no time remaining.

The shot by Matthews was clearly released before the game clock expired, but the shot clock was a much closer call. After a long review, officials ruled the ball was released in time.

"As heartbreaking as that was, we got that stop," Minnesota coach Richard Pitino said. "The ball kind of bounced their way."

Gabe Kalscheur's 3-pointer tied it at 57 with 30.9 seconds remaining, capping a 10-0 run for the Golden Gophers.

Brazdeikis scored 13 of his 18 points in the second half. He was held scoreless at Wisconsin on Saturday when the Wolverines lost for the first time this season. Michigan (18-1, 7-1 Big Ten) struggled through much of the game against Minnesota and was down by seven before Brazdeikis made a 3-pointer and a three-point play to cut the deficit to one. That was the start of a 23-3 run by the Wolverines.

Michigan led by 13, and then it was Minnesota's turn to rally.

Minnesota (14-5, 4-4) scored the first six points and led 19-10 after a 3 by Kalscheur. Michigan was 3 of 20 from the field before finishing the first half a bit better. The Golden Gophers led 31-28 at halftime.

DOUBLE-DOUBLES

Jordan Murphy scored 15 points with 11 rebounds for Minnesota, and Brazdeikis had 11 rebounds to go with his 18 points for Michigan. The last-second shot by Matthews was especially tough for Murphy and the Golden Gophers after they'd battled back to tie it.

"We were just hoping that it was a shot-clock violation so we could get a chance at overtime," Murphy said. "We think we were playing those guys pretty well. Obviously they made a big run in the second half, but we made a run back, so it was a pretty interesting game to play in. We just didn't finish out our defensive possession."

ALL EARS

Amid all the commotion on the final play, Michigan coach John Beilein liked what he heard.

"I trust my ears," Beilein said. "I saw the ball leave his hand, and I heard a buzzer go off, and that's usually a good sign."

BIG PICTURE

Minnesota: The way Michigan shot the ball in the first half, the Golden Gophers could have been up by more at halftime, but turnovers hurt. Minnesota had 10 in the first half while the Wolverines committed just two. The margin was 16-6 at the end of the game.

Michigan: This obviously wasn't an emphatic victory for the Wolverines after their weekend loss. A lot of their problems were because of outside shooting. They went 3 of 22 from 3-point range.

POLL IMPLICATIONS

An underwhelming win at home is unlikely to move the needle much for Michigan.

UP NEXT

Minnesota: The Golden Gophers host Iowa on Sunday.

Michigan: The Wolverines have a relatively quick turnaround before playing at Indiana on Friday night.

More from KARE 11 Sports:

Tommies continue winning ways with unique slogan

Rocco Baldelli hits the road with Twins Caravan

Payton: NFL admits they blew the call, costing Saints possible Super Bowl