Cubs find winning formula in victory against Nationals

Just as worries were mounting on the North Side amid a three-game losing streak, the Cubs looked and played the part of a first-place team Saturday.

The offense belted out two home runs, two doubles and nine hits in all. No. 5 starter John Lackey pitched well enough for five innings, and the bullpen allowed an unearned run to finish the job.

With a playoff vibe in the air and more than 40,000 fans on their feet, Wade Davis struck out five-time All-Star and 2015 National League MVP Bryce Harper with two runners on to preserve a 7-4 victory against the Nationals at Wrigley Field.

‘‘We’ll always take it any way we can get it,’’ manager Joe Maddon said, ‘‘but I do believe we can play with anybody. I really mean that sincerely.’’

There had been questions after the Cubs dropped a series to the Diamondbacks, then lost the first game of the series Friday to the Nationals. The Cubs have struggled at times to play up to the competition, but the victory put them in position to claim the series Sunday.

Edwin Jackson, making his first start at Wrigley since the Cubs released him in 2015, spotted the Cubs four runs in the first inning to help set the tone.

Jon Jay and Kris Bryant hit back-to-back doubles to start the first before Willson Contreras and Ben Zobrist singled to set up Alex Avila’s first homer in a Cubs uniform.

Maddon had said before the game that the Cubs would need to get to Jackson early because he settles in as the game goes on. True to form, Jackson allowed only one hit in the next four innings before being lifted.

‘‘He started gaining confidence in all his pitches and went to his slider more,’’ Maddon said. ‘‘I’ve always seen that with him. Once you permit him to get into a groove, he’s so athletic, he starts feeling his delivery.”

Contreras, who has been one of the hottest players in the league, added some insurance with a two-run homer in the sixth. It was his third homer in the last three games, and he has nine RBI in that span.

Asked after the game if he is punishing pitchers when they make mistakes, Contreras answered matter-of-factly.

‘‘That’s what hitting is all about,’’ he said. ‘‘Just be ready for your pitch and, if they give it to you, take it. I’m not giving them anything. So especially against this kind of team that can make a comeback at any time, I’m ready to hit.’’

Lackey allowed two earned runs in five innings before departing after 95 pitches. It was the fourth consecutive start in which he yielded two earned runs or fewer.

The Cubs’ bullpen then kept the Nationals in check. Brian Duensing extended his scoreless-innings streak to 15 1/3, and Pedro Strop, Justin Wilson and Davis pitched an inning apiece.

Harper, having already homered in the first, came up after Davis walked Jose Lobaton and Brian Goodwin to bring the tying run to the plate. He looked at a first-pitch ball, then fouled off two pitches before swinging and missing at a breaking ball.

‘‘The last curveball was an unbelievable pitch,’’ Avila said. ‘‘Pretty nasty. Looked like a fastball in and fell off the table. Perfect location, down and away. Looking for that swing-and-miss, couldn’t have asked for a better pitch.’’

Follow me on Twitter @davidjustCST.

RELATED STORIES

Willson Contreras, playing left field, continues his hitting barrage

MORRISSEY: One victory over the Nationals is worth a lot more