The Knicks and Bucks advance to the knockout stage of the NBA Cup

Giannis Antetokounmpo plays for the Milwaukee Bucks.

Giannis Antetokounmpo led the Milwaukee Bucks in scoring (Getty Images)

The Milwaukee Bucks and New York Knicks eased to victories to advance to the knockout stage of the NBA Cup with clean sheets in their groups, but the reigning NBA champions, the Boston Celtics, were eliminated.

The Knicks posted an emphatic 121-106 win against the Orlando Magic at Madison Square Garden to finish East Group A undefeated and secure home court advantage in the quarterfinals.

Karl-Anthony Towns scored 23 points and grabbed 15 rebounds, while Josh Hart contributed a triple-double of 11 points, 13 rebounds and 10 assists.

Despite the loss, the Magic won the East wild card spot on point difference over the Celtics, who also finished the group stage with a 3-1 record.

Giannis Antetokounmpo and Damian Lillard starred as the Bucks beat the Detroit Pistons 128-107 to win East Group B undefeated.

Antetokounmpo — the 2019 and 2020 NBA MVP — scored 28 points with seven rebounds and eight assists, while Lillard scored 27.

The Bucks hit 23 three-pointers during their seventh straight win and will host the Orlando Magic in the quarterfinals on Tuesday.

Elsewhere, a 37-point performance from Luka Doncic inspired the Dallas Mavericks to overcome a 15-point fourth quarter deficit to beat the Memphis Grizzlies 121-116 and clinch the West wild card spot.

They travel to the Oklahoma City Thunder in the next round after beating the Utah Jazz 133-106 to win West Group B over the Phoenix Suns.

The Knicks host the Atlanta Hawks — who won East Group C ahead of the Celtics — on Wednesday.

The Houston Rockets and Golden State Warriors will battle it out in the final quarterfinals after winning their groups despite last-game losses to the Sacramento Kings and Denver Nuggets, respectively.

The quarter-final winners advance to the semi-finals to be played on December 14 in Las Vegas, with the final three days later in the city.

In Tuesday’s other games, the LA Clippers beat the Portland Trail Blazers 127-105, the Phoenix Suns defeated the San Antonio Spurs 104-93 and the Cleveland Cavaliers beat the Washington Wizards 118-87.

The Philadelphia 76ers won on the road at the Charlotte Hornets (110-104), while the Toronto Raptors beat the Indiana Pacers 122-111.