Washington (dpa)
Although the United States likes to think of itself as the world's pre-eminent democracy, where each person can have their say about who should be president, the Constitution calls for states to choose "electors" who do the actual electing. It's known as the Electoral College.
Including the first presidential election in 1789, won by George Washington, there have been 59 US elections. In all but five - two in this century - the president has won both the popular vote and the Electoral College vote.
In 2000, Democratic candidate Al Gore garnered 543,895 more votes nationwide than Republican George W Bush. But in a contentious race that went all the way up to the Supreme Court, the judges decided to end a recount, giving Florida's then 25 electoral votes to Bush.
This took Bush past the magic number of 270 electoral votes and ensured him the presidency.
In 2016, when Donald Trump was elected, Hillary Clinton won the popular vote by a much bigger margin, receiving 2.9 million more votes nationwide. But Trump became president because he garnered 304 electoral votes to Clinton's 227.
If the number of electoral votes are tied, then the election is decided by the newly elected House of Representatives.
How the electoral votes work
Each state is allotted electors equal to their number of representatives in Congress.
This means there are 538 electors in total: 435 representatives and 100 senators, plus three for the District of Columbia. If a candidate wins 270 electors or more,
therefore, he or she wins the presidency.
In 48 states, the candidate with the most votes - however slim the margin is - wins all the state's electoral votes.
Maine and Nebraska do things differently and allocate electoral votes by individual congressional districts.
Some critics regard the Electoral College to be an anachronism and would replace it with a national popular vote.
They say that the Electoral College causes candidates to concentrate their campaigns primarily on a handful of swing states where the vote could go either way, turning the majority of voters elsewhere in the country into bystanders.
But proponents say the reverse would happen if the president were elected by the popular vote. Then candidates would concentrate their campaigning in the big states - California, Texas and New York - and voters in smaller states would be the onlookers.