New York: The presidential contest between Hillary Clinton and Donald Trump turned into a made-for-TV thrill ride on Tuesday night—and a stern lesson to journalists to avoid leaping to conclusions.

Relying on polls, the media began the evening with a barely-concealed assumption that Clinton would win, only to see actual results reflect a true nail-biter. Tens of millions of Americans followed the drama on all manner of screens.

“It is a white-knuckles kind of night,” said Norah O’Donnell of CBS News.

The New York Times’ Upshot blog’s constantly updating meter on the chances of each candidate began by listing Clinton with an 85% chance of winning. Shortly after 10pm, it had nearly flipped completely to 79% in favour of Trump.

It was a far different mood while the polls were still open. Vice Media and Slate collaborated on a system that combined exit polling with early voting profiles to project candidate vote totals in seven battleground states and posted the material throughout the day on Tuesday. Clinton was leading Tuesday afternoon in all seven of the states, according to the VoteCastr model.

Television networks vowed to stick with tradition and not reveal that information. But it was hard to miss some foreshadowing.

Trump called in to Fox News Channel shortly after 2 pm, where he talked about a rigged electoral system and passed up the chance to exhort supporters to vote. Fox interviewer Martha MacCallum asked him four questions about what he might do if he lost.

Shortly thereafter, Republican National Committee aide Sean Spicer on Fox offered a very specific prediction—that Trump’s electoral vote total would exceed those of President Barack Obama’s two opponents—without predicting victory. Republican pollster Ed Rollins told Fox’s Shepard Smith at 3 pm ET that it would take a miracle for Trump to win.

“I hear they’re confident,” Blitzer said. “Are they very, very confident or are they nervous?”

Responded Keilar: “I’m not picking up any nerves.”

A CNN discussion of heavy Latino voting caused Trump surrogate Kayleigh McEnany to warn that writing a headline that Latinos delivered victory to Clinton was premature.

“I said, ‘if,’” noted anchor Jake Tapper.

Five hours later, Tapper said it was the kind of night that would put the polling industry out of business.

Even before the polls closed, there were warnings not to jump to conclusions too early. “Please keep in mind, exit polls can shift faster than a feather in a tornado,” tweeted former CBS News anchor Dan Rather, in his familiar folksy style.

As the hours went on, the mood brightened at Trump headquarters in New York City, and became more sombre a few blocks south where Clinton’s supporters were gathering.