MADISON, Wis. (AP) Nigel Hayes was in vintage form, going strong to the hoop. Bronson Koenig returned from a leg injury to provide a jump-shooting boost off the bench.

No. 11 Wisconsin played like it was fighting to get into the NCAA Tournament, even if the Badgers are virtually guaranteed to be playing into mid-March.

Hayes scored 14 of his 21 points in the second half, and Ethan Happ had 20 points to beat No. 23 Maryland 71-60 in a choppy, foul-filled game on Sunday.

The Badgers (22-5, 11-3) overcame 27 points from Terrapins guard Melo Trimble to snap a two-game losing streak and stay in a tie atop the Big Ten standings with Purdue.

After consecutive losses to Northwestern and Michigan - two squads looking to pad their resumes just to get into the NCAAs - Wisconsin took the court with the mindset of a bubble team trying to prove a point.

''I would definitely say `Yes,' that's kind of why we dropped the last two,'' Hayes said when asked if his team was playing with a sense of urgency.

Northwestern and Michigan ''were fighting for their tournament lives, trying to build a resume,'' Hayes said. ''We finally have that sense of urgency on our own end.''

Koenig scored all nine of his points in the second half, giving the Badgers a lift with his jump shot after the senior missed a game with a nagging left calf injury. Wisconsin shot 51 percent in the second half.

Wisconsin pulled away slowly, turning a six-point halftime deficit into a 12-point edge with 3 minutes to go.

''Those guys just dominated,'' Maryland coach Mark Turgeon said about forwards Hayes and Happ. ''We couldn't guard them heads-up. We couldn't guard them in a double-team.''

But they did draw whistles in a physical game at the loud, rowdy Kohl Center. The game lacked flow because of frequent foul calls. The schools combined for 48 fouls, 25 for Maryland (22-5, 10-4).

''Extremely physical. We'll be running the training room out of ice after the game,'' Wisconsin coach Greg Gard said.

BIG PICTURE

Maryland: Trimble followed up his career-high 32 points in a win at Northwestern with another good game on the road. He had 15 in the first half, including two 3s in the final 1:11 to give the Terrapins a 33-27 lead. Trimble was averaging a team-best 17.0 points in road games coming into Sunday.

Wisconsin: Shooting lagged over the previous six games, a stretch when Koenig has been hurt. He's the team's best outside shooter. After missing his first three shots in the first half, Koenig went 4 of 8 from the field in the second. A productive Koenig gives Wisconsin the balance needed to go with the dangerous Happ in the post. Koenig played 31 minutes off the bench.

Wisconsin said Koenig was a game-time decision, and Gard said the team prepared on Saturday as if he was not going to play.

MELO TIME

For a while, it looked like Trimble would carry Maryland to another road win all by himself. He finished 9 of 17 from the field and regularly hit 3s from the wing.

But the Badgers held on despite Happ spending much of the second half on the bench saddled with four fouls. Hayes took up the slack with an active day in the paint, grabbing 10 rebounds.

Turgeon had seen enough and pulled Trimble from the game with 4:32 left and his team trailing by 12 points.

''He was tired,'' Turgeon said. ''We've got four games in 10 days ... Wisconsin was in total control of the game.''

STAT LINES

Freshman Brevin Pritzl added seven points and seven rebounds, giving Wisconsin an energy boost off the bench. Another freshman, D'Mitrik Trice, was active starting his second straight game for Koenig, with seven points in 19 minutes. ... After Trimble, Michal Cekovsky was the only other Maryland player in double figures with 10 points.

QUOTABLE

''We didn't fade away. We went strong through people ... When we do, it makes us really good.'' - Gard about the team's aggressiveness, especially in the lane. Wisconsin had a 22-10 edge in the second half on points in the paint.

UP NEXT

Maryland: Hosts the first of two straight home games when Minnesota visits College Park on Wednesday.

Wisconsin: Tries to sweep the season series from Ohio State with a trip to Columbus on Thursday.

---

More AP college basketball: www.collegebasketball.ap.org and https://twitter.com/AP-Top25 .

---

Follow Genaro Armas at https://twitter.com/GArmasAP

Copyright 2017 by STATS LLC. Any commercial use or distribution without the express written consent of STATS LLC is strictly prohibited.