US President Donald Trump makes his way to board Marine One from the South Lawn of the White House in Washington, DC on November 2, 2018. - Trump will be attending rallies in West Virginia and Indiana. (Photo by MANDEL NGAN / AFP)        (Photo credit should read MANDEL NGAN/AFP/Getty Images)
PHOTO: MANDEL NGAN/AFP/Getty Images
US President Donald Trump makes his way to board Marine One from the South Lawn of the White House in Washington, DC on November 2, 2018. - Trump will be attending rallies in West Virginia and Indiana. (Photo by MANDEL NGAN / AFP) (Photo credit should read MANDEL NGAN/AFP/Getty Images)
Now playing
02:13
Trump braces for Democrat-led investigations
Now playing
02:11
'Sad': Kinzinger blasts Hawley's CPAC remarks
New York Gov. Andrew Cuomo speaks during a news conference at a COVID-19 vaccination site in the Brooklyn borough of New York, Monday, Feb. 22, 2021. (AP Photo/Seth Wenig, Pool)
PHOTO: Seth Wenig/Pool/AP
New York Gov. Andrew Cuomo speaks during a news conference at a COVID-19 vaccination site in the Brooklyn borough of New York, Monday, Feb. 22, 2021. (AP Photo/Seth Wenig, Pool)
Now playing
01:12
Gov. Andrew Cuomo responds to allegations of sexual harassment
 Psaki biden White House Khashoggi Saudi Arabia sotu bash vpx _00011629.png
PHOTO: CNN
Psaki biden White House Khashoggi Saudi Arabia sotu bash vpx _00011629.png
Now playing
03:42
Bash to Psaki: Why hasn't Saudi Arabia been held accountable for murder of Khashoggi?
Speaker of the Virginia House of Delegates Eileen Filler-Corn (D-Fairfax) speaks during opening ceremonies of the 2020 Virginia General Assembly at the Virginia State Capitol on January 8, 2020 in Richmond, Virginia.
PHOTO: Zach Gibson/Getty Images
Speaker of the Virginia House of Delegates Eileen Filler-Corn (D-Fairfax) speaks during opening ceremonies of the 2020 Virginia General Assembly at the Virginia State Capitol on January 8, 2020 in Richmond, Virginia.
Now playing
04:26
Virginia's political shift from red to purple to blue
senator bill cassidy sotu bash vpx _00002611.png
senator bill cassidy sotu bash vpx _00002611.png
Now playing
01:42
GOP senator: If we continue to idolize one person, we will lose
Now playing
01:27
Kristi Noem gets standing ovation for Dr. Fauci dig at CPAC
House Speaker Nancy Pelosi
PHOTO: House TV
House Speaker Nancy Pelosi
Now playing
02:52
House passes Biden's $1.9 trillion Covid-19 relief package
covid-19 relief package house biden sot malveaux nr vpx _00000000.png
PHOTO: CNN
covid-19 relief package house biden sot malveaux nr vpx _00000000.png
Now playing
02:28
CNN's Joe Johns explains Biden's short speech as relief bill heads to Senate
Sen. Bernie Sanders AC360 intv 02262021
PHOTO: CNN via Cisco Webex
Sen. Bernie Sanders AC360 intv 02262021
Now playing
03:54
Sanders on what happens with proposed minimum wage increase now
WASHINGTON, DC - JANUARY 17: The U.S. Capitol dome is seen beyond a security fence on January 17, 2021 in Washington, DC. After last week
PHOTO: Michael M. Santiago/Getty Images
WASHINGTON, DC - JANUARY 17: The U.S. Capitol dome is seen beyond a security fence on January 17, 2021 in Washington, DC. After last week's riots at the U.S. Capitol Building, the FBI has warned of additional threats in the nation's capital and in all 50 states. According to reports, as many as 25,000 National Guard soldiers will be guarding the city as preparations are made for the inauguration of Joe Biden as the 46th U.S. President. (Photo by Michael M. Santiago/Getty Images)
Now playing
02:33
This is what's in the $1.9 trillion coronavirus package
PHOTO: CNN
Now playing
02:24
Acosta corrects CPAC organizer: Trump did lose the election
PHOTO: Pool
Now playing
01:10
Rand Paul accused of 'transphobic attack' in confirmation hearing
PHOTO: CNN
Now playing
02:39
Republicans push new restrictive election bills in 43 states
van jones minimum wage
van jones minimum wage
Now playing
02:44
Van Jones: This is a make or break issue for Democrats
US President Joe Biden speaks about the 50 million doses of the Covid-19 vaccine shot administered in the US during an event commemorating the milestone in the Eisenhower Executive Office Building in Washington, DC, February 25, 2021. (Photo by SAUL LOEB / AFP) (Photo by SAUL LOEB/AFP via Getty Images)
PHOTO: Saul Loeb/AFP/etty Images
US President Joe Biden speaks about the 50 million doses of the Covid-19 vaccine shot administered in the US during an event commemorating the milestone in the Eisenhower Executive Office Building in Washington, DC, February 25, 2021. (Photo by SAUL LOEB / AFP) (Photo by SAUL LOEB/AFP via Getty Images)
Now playing
02:28
Axelrod explains the message Biden is sending with strike
(CNN) —  

Democrat Jared Golden defeated Republican Rep. Bruce Poliquin in Maine’s 2nd District House race – flipping the seat after the state calculated its ranked-choice voting results.

It’s the first time in the nation’s history a federal race has been decided by ranked-choice voting.

Golden won 50.5% to Poliquin’s 49.5%, Maine Secretary of State Matthew Dunlap told reporters Thursday afternoon. The flip means Democrats have picked up 33 House seats so far in 2018, with seven races still undecided. Democrats lead in five of those seven seats, all of which are Republican-held districts.

So far, the current balance of power in Washington come January will be 228 Democrats and 200 Republicans in the House.

The tabulation came hours after a judge denied Poliquin’s request for a temporary restraining order. The Republican had called into question the constitutionality of the ranked-choice voting process, which Maine’s voters approved in a 2016 referendum and used for the first time this year.

In Maine’s system, voters rank their choices from first to last. If no candidate gets more than 50% of the first-place votes, then candidates are eliminated one by one – making the second-place choices of voters who back little-known third-party or independent candidates crucial.

Poliquin narrowly led Golden, 46.2% to 45.6%, after first-place votes were counted. But more than 8% of Maine’s voters backed one of the two independent candidates in the race, Tiffany Bond and Will Hoar.

Dunlap’s office calculated the ranked-choice voting results Thursday afternoon, broadcasting their Microsoft Excel tabulation on Facebook Live.

Poliquin didn’t concede after the results were announced, instead saying he will continue his legal challenge of the constitutionality of Maine’s ranked-choice voting system.

“It is now officially clear I won the constitutional ‘one-person, one-vote’ first choice election on Election Day that has been used in Maine for more than one hundred years. We will proceed with our constitutional concerns about the rank vote algorithm,” Poliquin said in a statement.