With opinion polls suggesting no party is likely to form a majority government on Monday, the question widely asked at this point in the campaign is, "What happens if Stephen Harper wins the most seats but does not reach a majority?"
There is much evidence the other parties would move to prevent him from continuing as prime minister, and Canadians appear to support the idea.
- VOTE COMPASS | Find out where you stand
- PLEDGE TO VOTE | Ready to commit?
- LIVE BLOG | Breaking news from the campaign trail Tuesday
- POLL TRACKER | Follow the latest numbers
Harper has won minority governments before and carried on as prime minister with periodic support of one of the other parties.
His main opponents have said that won't happen this time. Liberal Leader Justin Trudeau has said there are "no circumstances under which I could support Harper," while the NDP's Tom Mulcair put it plainly: "Not a snowball's chance in hell."
So how would this sort itself out? The leaders acknowledge that in our system the sitting prime minister has the first chance to form government, especially after winning the most seats.
Bob Rae, who has been around various minority governments during his long career in politics, agrees Harper has the initial advantage.
"Certainly, if Mr. Harper has the most seats after the election, he can go to the Governor General and say, 'I got the most seats, so I get to try.' But that's the sentence. He gets to try," Rae says.
"The House of Commons will decide who's going to be the prime minister, for how long," he adds. "That's our system."
In a minority situation, Harper would have a couple of options, depending on the seat numbers.
He could just give up right away and ask the opposition parties to form a government because collectively they would have more seats. Or, as the one with the most seats, Harper could fight to remain prime minister with a speech from the throne about his government's legislative intentions.
Based on what Trudeau and Mulcair have said, he'd almost certainly lose a confidence vote in the House. That's when it would get interesting.
Governor General's decision
Harper could argue that if he doesn't get to govern despite having the most seats, another election must be called. But Gov. Gen. David Johnston could reject that and ask the opposition parties to try to form a government of their own. Especially if that's what they are already offering to do.
There is precedent in Canada for the winning party being knocked out after an election.
It occurred in Ontario in 1985. Progressive Conservative Premier Frank Miller won more seats than David Peterson's Liberals, and to sustain his minority government, Miller turned to the third party — the New Democrats — led at the time by Rae.
The Conservatives told the New Democrats to name the price for their support, but Rae refused.
"They wanted to be very generous. It wasn't about that. It wasn't about what was on offer, it was about, I think, a political judgment on the part of the New Democrats at the time, that it was time for a change," Rae recalls. "And there was enough of a common agenda between the Liberals and the New Democrats that it could create an agenda for a government. And it did, for two years."
The Ontario NDP and Liberals signed a formal accord laying out a legislative agenda and a guarantee there would be no election for at least two years.
Former Conservative senator Hugh Segal was then representing the Tories in the negotiations and had no problem with the decision to give up power. Similarly now, he says, the Governor General will have to consider who has a legitimate right to govern regardless of who wins the most seats.
"[Johnston] is a Governor General [who] is particularly well versed in constitutional matters, so if there's any way a government can continue and do its job and still be legitimate, he has a duty to be constructive and supportive.
"He's not driven by polls. He'd want to know the legitimacy of the other parties after a confidence vote and he'd have to assess and weigh it based on the circumstances at the time."
'Losers' sometimes do form government
A few years ago on a visit to Great Britain, Harper suggested any coalition of parties that lost an election would be illegitimate. "Losers don't get to form coalitions. Winners are the one that form governments," he said.
Former NDP leader Ed Broadbent disagrees.
"That's just factually wrong, and it's an anti-democratic attitude. Continental European governments are what we call minority governments and are frequently made up of 'losers.'
"The key thing, constitutionally, is when you add them up they have majority support. It's 50 per cent plus one."
Segal has a different view. "It's one thing if there's been a huge shift, the government's hanging on by its fingernails and only has a few seats of a plurality. But if they have a substantial plurality — if there's a 50-seat plurality on behalf of the government — it is very much running on the side of the government in the process."
The general feeling is if the Conservatives were heavily outnumbered, Harper would likely give up power. If, however, he is just a few seats short of a majority, he would likely hold on. That's the view of Andrew MacDougall, who used to work as Harper's director of communications.
"Size does matter, and the way I look at this, it's a bit like political pornography: you'll know it when you see it and you'll know the margin when you see it."
Can they get along?
Mulcair and Trudeau have been sniping a lot at each other in this campaign, which MacDougall says will make it harder for them to get along after Oct. 19.
"They would have to form a government and try to convince Canadians that they had a program, and let's remember nobody in this election is voting on the basis of what the NDP and Liberals would look like together."
How Liberal and NDP voters feel about their parties working together has been a preoccupation of EKOS pollster Frank Graves. In an exclusive poll shared with CBC News, he found that to get rid of the Harper government, both Liberal and NDP voters overwhelmingly favour a Liberal-NDP coalition government — and who would be the new prime minister doesn't seem to matter.
"This reinforces the fact that the coalition, far from being a bogeyman or some kind of sketchy idea that we don't really want to try, is really an enormously resonant idea with frustrated voters on the centre-left today," says Graves.
Broadbent has an explanation.
"I think there's more visceral antipathy towards the prime minister than there has been in the recent past, and that reflects itself in many Canadians desiring the opposition parties to collaborate in some way constructively, to provide stability, but also to provide progressive change."
Graves says his numbers support that.
"We find there's scant distance between NDP and Liberal voters. They are largely what we call 'promiscuous progressive voters' that have been casting back and forth across the NDP and the Liberals looking for a better bet to get a new government and a progressive government.
"NDP voters overwhelmingly list the Liberals as their preferred second choice, so do Liberals [list the NDP]," he says.
The last attempt at a federal coalition in 2008 flamed out because of the involvement of the Bloc Québécois. During the last election, Harper often used the possibility of a coalition to scare voters.
But the situation now is different, especially because the separatist BQ wouldn't be a factor, says Graves.
"I don't think it has the same potency or value as a late-stage tactic that it did, and it was an effective tactic in 2011. The level of fluency in the public about coalitions is much higher today than it was 10 years ago. They've debated this issue, they've heard about it, they've seen it occurring in other countries, their aversion is much lower."
It is clear that if Harper wins a minority, the pressure on the other party leaders to depose him will be overwhelming. To begin with, it will come from former leaders like himself, says Broadbent.
"The other parties have, I would argue, not only the constitutional right, but the constitutional obligation early after an election in Canada to put together an arrangement in government to provide some stability in Canada, and in this case also some elements of progressive change in policy."
But whatever it is, says Segal, it probably won't be a formal coalition.
"I think it's very rare within the context of Canada's present political culture that you'd see a coalition between the two opposition parties. It is more likely that one of the opposition parties would say to the other, you form a government, we have terms and conditions for your throne speech, for your budget, and we will give you confidence for a couple of years at least, provided we move along that path."
Risk of 'political suicide'
In 2009, Liberal leader Michael Ignatieff decided to temporarily support a continuation of the Harper minority government.
Graves believes an opposition party propping up Harper this time would risk "political suicide."
"The intensity of desire for change amongst those in their portion of the electorate is really, really high, and frankly I would expect that you would find people with pitchforks and torches on Parliament Hill if those parties say, 'Well we're going to look the other way and let Mr. Harper rule.'"
Among those who seem favourably disposed to coalitions is the Governor General himself.
In a rare 2010 interview, he said: "I think that most jurisdictions … will from time to time have coalitions or amalgamations of different parties, and that's the way democracy sorts itself out."
Harper might have a tough time convincing him that is not the case.
EKOS report on attitudes about coalitions
EKOS report on attitudes about coalitions (PDF KB)
EKOS report on attitudes about coalitions (Text KB)