The leader of the Social Democrats, Helle Thorning-Schmidt, is the favourite to win the election in Denmark on Thursday, 15 September. She will have a tough challenge. She is leading a party that is on its way towards a disappointing result, and she will have to lead a disconnected coalition.
If the trend in the opinion polls holds true, the leader of the Social Democrats, Helle Thorning-Schmidt, will be the new Danish prime minister on Thursday evening, when all the votes have been counted after an intense and hectic election campaign.
That will be the end of an unusual decade in Danish politics where tight immigration policies, the crisis of the controversial cartoons of the prophet Muhammed in the newspaper Morgenavisen Jyllands-Posten, and involvement in the wars in Iraq, Afghanistan and Libya have changed the outside world's opinion of Denmark.
In this decade, a Liberal/Conservative government, led first by Anders Fogh Rasmussen and later by Lars Løkke Rasmussen, has been in power. Supported by the Danish People's Party, which has acted as the government's loyal support party and been rewarded by being invited right into the powerhouse by Anders Fogh Rasmussen.
If Helle Thorning-Schmidt becomes head of government on Thursday evening - after she has been in the lead for a long time in the opinion polls - a new and different era will begin. But what one?
It goes without saying that Thorning will be celebrated as a heroine by her supporters on election night if the Social Democrats succeed in capturing the Prime Minister's office.
For 10 long years the party has been kept out of the corridors of power and been relegated to the hard opposition benches. So it will be a triumph for her fellow party members to see their leader become prime minister - and their enthusiasm will be none the less as Thorning will be able to write Danish history as the nation's first woman head of government.
It will presumably quickly be seen to be harder to keep power than it was to win it. Thorning can hope that, in her first period as prime minister, she will be surrounded by so much positive media interest that the Danes will look more kindly towards her than today and have more confidence in her skills.
If that happens, she will grow with the challenge, and she will have the chance to surprise many with her leadership. She has many of the qualities required to make a good prime minister. She has an unusually robust personality, can make decisions, she is good at communicating and likes to be "on" in the media, she is systematic, a quick learner and will work well together with all the officials in the central administration, who are ready to help her with the formulation of policy and technical solutions.
When Denmark takes over the Presidency of the EU in the new year, it will be a good guess that the surrounding world will take notice of a dynamic head of government who will do everything possible to run a professional presidency, and who, also, can talk to the other heads of state and government in perfect English. The latter is due in no small part to the fact that she is married to Stephen Kinnock - son of the former Labour leader Neil Kinnock.
Having said that, Thorning will need all her energy and resolution if she is to be successful as prime minister, because she will face colossal challenges and she does not have an overwhelming amount of experience.
In her six years as leader of the Social Democrats she has indeed proven that she can accomplish a great deal. She took over a party at a historic low point where her fellow party members were divided into factions that were often more concerned with fighting each other than defeating the government. Thorning has managed to establish a ceasefire, which has effectively put an end to the old disputes.
Next, she has entered into a close alliance with the Socialist People's Party (SF) a bit further out to the left, which has been crucial to the possibility that there could be a real alternative in the eyes of the electorate. These two parties have been able to present proposals, for example, in judicial and immigration policies as well as taxation policies and general economic policy.
Along the way the Social Democrats and SF have jointly implemented a marked swing to the right in value policies - as they say in Denmark. That means that S and SF by a long stretch have usurped the government’s and the Danish People's Party's tight immigration policy. In this way the two parties have effectively closed their former open flanks towards to the Liberal/Conservative parties and the Danish People's Party. For the Social Democrats this shift towards a tighter immigration policy has meant that the party has come more in tune with the majority of its voters.
And yet, it will be a completely different challenge to take over the government and lead a country.
A sober analyse is that Thorning has probably mostly won as the result of a rejection of a government that has been in power for 10 years and less as the result of a straight choice for a new government.
One of the paradoxes of the election campaign is that on Thursday evening Thorning could be celebrated as Denmark's first woman prime minister and at the same time stand out as the Social Democratic leader who has delivered the worst election results in history. Polls show that the Social Democrats only stand to win about 25 per cent of the votes and that is the same low level as the dreadful election result of 2007.
One of the reasons is that the Danes have considerable doubt about Thorning and are concerned about whether she has the skills needed to lead Denmark through the economic crisis. This is probably because Thorning - and the majority of her team - have no experience of being members of a government.
Then it is clear that it is not only the Social Democrats who are weakened. Thorning's closest co-operation and alliance partner, the Socialist People's Party led by Villy Søvndal, is very far from top form after several years with steep growth curves.
Today SF has slid far down the slope compared to the record polls in 2010 and there is a risk that the party will have a worse election result than in 2007. The explanation is that Villy Søvndal has damaged the party by making so many compromises with Thorning that, in the eyes of the voters, it has almost become a branch or subsection of the Social Democrats.
Among SF's support base there is clear frustration over the new centrist line and, although gaining power will provoke great jubilation, Villy Søvndal has the problem that his party has peaked before the hard work of government kicks in.
It's a good guess that SF's voters will react with disappointment and anger when it dawns on them that Søvndal as a new minister will have to make tough and unpopular decisions. A party like the Social Democrats can deal with that because it is in the party's DNA to bear responsibility and because the leading politicians realise that there is a price to pay for power. SFs have never tried this before and the SF leadership has both before and during the election campaign made promises which will be impossible to fulfil.
The fact of the matter is that neither Thorning nor Søvndal have managed to move their parties forward in the election campaign and so they will be strongly dependent on the election campaign’s more successful parties in red blue - namely the centrist Social-Liberal Party (Det Radikale Venstre) and the Red-Green Alliance (Enhedslisten) on the extreme left-wing.
It is obviously lucky for Thorning that these two parties have done so well because otherwise she would find herself a long way from the Prime Minister's office today. On the other hand, it is a serious problem that the Social-Liberal Party and the Red-Green Alliance are in direct confrontation in economic policy.
While the Red-Green Alliance reject, amongst other things, increased working hours, reduced early retirement benefit and higher retirement age - which all economists consider crucial to protect the Danish economy - the Social-Liberal Party stands for a definite reform agenda. The two parties are like fire and water in taxation policy too.
The two are, however, in agreement in immigration policy - they both believe that the strict rules should be slackened considerably - but here, on the other hand, they are in open conflict with the Social Democrats and SF.
In other words, Thorning risks being caught in a dangerous cross pressure if she doesn't manage to expand her power base and establish co-operation across the middle with the liberal/conservative parties, especially in economic policy.
She will be forced to accept the Social-Liberal's demands in economic policy, and even though the S leader hasn't said as much publicly, she will be forced to take over a number of the reforms - including the retirement reform with reduced early retirement pension and higher retirement age - which the government has implemented and which she has thundered against. If Thorning says no, the Social-Liberals will not join a government with S and SF. And without the Social-Liberals Thorning will be extremely vulnerable as prime minister.
There are difficult economic challenges ahead, which the election campaign has very clearly illustrated. A few years ago the politicians were all fighting about how to divide the money. During this current election they have first and foremost debated how they are even going to find the money for welfare.
In the first week of the election it was made clear that Denmark is not - luckily - in a recession as the preliminary economic figures earlier in the summer had suggested. But the economy is fragile. And the downturn in the world economy has further increased the pressure on Denmark.
The cost of the welfare that most Danes want to form a circle around will increase when the large older generations retire from the labour force and fewer young people are ready to produce prosperity. In addition, Denmark - just like the other Nordic countries - is being squeezed by steady fiercer competition from the new successful winner economies.
The election campaign has clearly shown that the Danes are worried about the economy and the figures are so dismal that former prime minister, NATO's Secretary General Anders Fogh Rasmussen's old agendas have been pushed into the background. Gone is the talk of value politics and culture fights.
Gone is the emotional debate on immigration policy which took up so much of the elections in 2001, 2005 and 2007. However, do not misjudge the attitude of the voters. What is new in this election is that the Danes are no longer demanding tightening of immigration laws, but on the other hand, nor do they want the immigration laws to be rolled back.
In other words, Thorning can make probably make adjustments but not make a showdown with the immigration policy that Anders Fogh Rasmussen introduced in 2001.
If she tries to do that she will quickly push the voters back to the blue block. For the same reason, the Danish People's Party cannot be written off. They will continue to play the role of the most stalwart and uncompromising defender of tight immigration policy.
All in all, the task for the country's new prime minister is monumental, regardless of party affiliations.
If the polls are correct Thorning will get the chance in a few days to show what she can do with this task. If it turns out that prime minister Lars Løkke Rasmussen, against all odds, manages to turn the election campaign in the last 24 hours, the story will come to a sudden end for Thorning.
If she loses on Thursday, she will soon be writing former party leader on her business card.