CHICAGO (AP) Aaron Hicks slid across home plate, hopped up and flexed his arms in jubilation.

No Monday morning blues for Hicks and the New York Yankees.

Hicks scored on Starlin Castro's grounder in the 18th inning, and the rolling Yankees beat the Chicago Cubs 5-4 in the majors' longest interleague game ever by innings.

''We're going to grind out games,'' Hicks said. ''We're going to fight to the end.''

The teams combined for a major league-record 48 strikeouts in baseball's longest game of the season by innings, wrapping up in a tidy 6 hours, 5 minutes, and ending after 1 a.m.

''I know we lost, but you've got to try to have fun with it,'' Cubs slugger Anthony Rizzo said.

Hicks struck out four times, but he came up with a huge play in the final inning. He led off with a bunt single against Pedro Strop (0-2) and advanced to second when catcher Willson Contreras threw the ball into right field for an error.

With one out and Hicks on third, Castro hit a bouncer up the middle. Shortstop Addison Russell tried to throw home, but it was wide and Hicks scored easily.

Chasen Shreve (1-0) pitched three scoreless innings, striking out pinch-hitting pitcher Kyle Hendricks with runners on first and second for the final out in New York's fifth straight win. The Yankees (20-9) improved to 19-5 since they opened the season with four losses in five games. They also matched their high-water mark from last season at 11 games over. 500.

''It's just a crazy game,'' manager Joe Girardi said.

Chicago trailed 4-1 before it rallied in the ninth against Aroldis Chapman, who helped the Cubs win the World Series last year for the first time since 1908. Albert Almora Jr. and Javier Baez each singled in a run before Chapman hit slumping slugger Anthony Rizzo on his left forearm with the bases loaded on his 36th pitch, forcing home the tying run.

Rizzo got an X-ray on his arm and it came back negative.

''Thank my parents I drank my milk when I was a kid,'' Rizzo said. ''Decent bones.''

Tyler Clippard then came in and got Ben Zobrist to bounce to second for the final out. It was Chapman's first blown save since Game 7 at Cleveland.

''I felt normal. It just wasn't my night tonight,'' Chapman said through a translator.

Before Hicks scampered home with the winning run, the biggest highlight of extra innings belonged to Cubs slugger Kyle Schwarber. The left fielder went into the stands in foul territory for an outstanding catch on Chase Headley's foul popup in the 12th.

''Tremendous play,'' Cubs manager Joe Maddon said.

What was left of the crowd also sung along when the Cubs showed a tape of Harry Caray singing ''Take Me Out To The Ball Game'' for the second seventh-inning stretch in the 14th.

Jacoby Ellsbury hit a two-run homer for New York, and Aaron Judge had a run-scoring triple. Ellsbury went 2 for 6 in his first start since he bruised a nerve in his left elbow last Monday.

Baez homered for the Cubs, and Schwarber doubled twice. Jon Lester struck out nine in seven sharp innings in his 30th career start against New York.

Luis Severino had a similar line for New York, bouncing back nicely from a shaky start against Toronto last Monday. The right-hander allowed one run and four hits in seven innings.

WORTH NOTING

The Yankees set franchise strikeout records for pitching with 26 and hitting with 22 Ks. The previous single-game records were 19 for pitching and 17 for batting.

TRAINER'S ROOM

Cubs: OF Jason Heyward was out of the starting lineup for the second straight day with a sore knuckle on his right hand. ... LHP Brett Anderson was placed on the 10-day disabled list with a lower back strain. The Cubs also optioned LHP Rob Zastryzny to Triple-A Iowa and recalled RHP reliever Justin Grimm and INF Tommy La Stella from their top farm club.

UP NEXT

Yankees: Masahiro Tanaka (4-1, 4.46 ERA) gets the ball Monday for the opener of a two-game set in Cincinnati. He faces fellow right-hander Rookie Davis (1-1, 7.36 ERA), who was acquired by the Reds when they traded Aroldis Chapman to the Yankees in December 2015.

Cubs: Jake Arrieta (4-1, 4.63 ERA) starts for the Cubs on Monday in the opener of a three-game series at Colorado. Right-hander Antonio Senzatela (4-1, 2.84 ERA) pitches for the Rockies.

---

More AP baseball: https://apnews.com/tag/MLBbaseball

---

Jay Cohen can be reached at http://www.twitter.com/jcohenap

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