Britain drew closer to selecting a new prime minister Wednesday after Foreign Secretary Liz Truss and former Treasury chief Rishi Sunak were chosen as finalists by Conservative party lawmakers. Trade Minister Penny Mordaunt finished out of the running in third place in the voting to replace Boris Johnson.

Both Truss and Sunak have played key roles in public office in recent years. Truss has guided Britain’s response to Russia’s invasion of Ukraine, while Sunak helped lead Britain’s economy during much of the coronavirus pandemic.

One of them will replace Johnson as prime minister come September 5, after he was forced to resign amid several scandals that undermined his leadership of the country.

Johnson gave notice of his resignation in early July after his party decided the scandals had adversely affected his ability to lead the country.

Johnson appeared in his final parliamentary meeting Wednesday and received a round of applause from Parliament members following his exit.

After three years in charge, Johnson answered his final round of “Prime Minister’s Questions,” which is a weekly question-and-answer session between members of Parliament and the prime minister. Johnson’s opponents throughout the session used their questions to grill him on current policies, ranging from soaring living costs to the unfinished Brexit process.

A handout photograph released by the U.K. Parliament shows Britain's Prime Minister Boris Johnson speaking during his final Prime Minister's Questions at the House of Commons in London on July 20, 2022.

A handout photograph released by the U.K. Parliament shows Britain’s Prime Minister Boris Johnson speaking during his final Prime Minister’s Questions at the House of Commons in London on July 20, 2022.

However, Johnson still highlighted some of his successes throughout his leadership.

“I want to use the last few seconds … to give some words of advice to my successor, whoever he or she may be. Number one: Stay close to the Americans. Stick up for the Ukrainians. Stick up for freedom, for democracy everywhere.”

Despite the number of Parliament members who resigned over Johnson’s leadership, the prime minister left with a round of applause from most members.

His final words rang through the building as he said, “We’ve helped, I’ve helped, get this country through a pandemic, and help save another country from barbarism. And frankly, that’s enough to be going on with. Mission largely accomplished,” Johnson said.

“I want to thank everybody here, and hasta la vista, baby.”