In an asymmetrical war between a militant group and the world's fourth largest military, victory for the underdog would seem impossible. But in the bloody battle between Hamas and Israel, the terms of victory appear asymmetrical too.
Despite weeks of violence in Gaza that has killed nearly 2,000 Palestinians compared with only 64 IDF soldiers and three Israeli civilians dead, experts have told The Huffington Post UK that the war has unequivocally weakened Israel's position and strengthened that of Hamas.
Before the violence, the militant group was increasingly isolated and powerless, so much so it agreed to be the partner in a Palestinian unity government with its more moderate rival Fatah, despite Hamas having no ministers in its cabinet.
For weeks, graphic images of bombing and killing in Gaza dominated headlines. Because Hamas lacks a conventional military to target and because it is so embedded within the population of the densely-populated strip, Israel's military efforts killed far more civilians than Hamas militants - 72% of the dead were civilians, according to the UN - and the devastation it wrought has proved counter-productive.
Experts say Hamas, whose charter commits it to the destruction of Israel, is now more popular than before the war, and some believe will now have to be included in the future of any Palestinian state.
Hamas supporters chant slogans of resistance during a march in Rafah, Gaza on August 17
The Jewish state attacked the strip saying it would make Hamas, the governors of Gaza, "pay" for firing rockets at civilian targets and for the abduction and murder of three teenagers in the West Bank, which Israel accused Hamas militants of plotting.
Professor Rosemary Hollis, a Middle East expert at City University In London, said Hamas were in a "very weak position" before the war, but after weeks of bloody fighting, it appeared stronger now than before the Israeli offensive began on July 8.
"The injury done to the Palestinian people has, in the short team, increased the support for Hamas because they blame Israel, not Hamas, for the terrible trail of death and injury (in Gaza)."
The fall of the president Morsi in neighbouring Egypt in July last year had been a big blow to Hamas, Prof Hollis said, when that country's new regime destroyed smuggling tunnels that provided limited relief from the Israeli blockade, costing Hamas a key source of taxation income and supply.
Another blow has been the Syrian Civil War, where the group distanced itself from the Assad regime and publicly threw its weight behind the rebels, costing it a major ally.
Shlomi Eldar, an award-winning journalist, documentary maker and Hamas expert, told HuffPost UK that the war had "emboldened" the militants and brought it out of "crisis", at a time when it was even struggling to pay its own employees.
"I have many friends in Gaza. They blame Israel. Many, many families - every family - has lost at least person in the last three military campaigns [by Israel in Gaza]," he told HuffPost UK, adding Hamas representatives are now being "treated like heroes" for their resistance.
Asked whether he thought Hamas had "won" the war in Gaza, Eldar said: "I think so, unfortunately. Israel started this campaign with the slogan 'Hamas will pay'. Hamas didn't pay."
He added: "It was a terrorist victory. 2,000 people were killed and 10,000 were injured. It's awful."
Although there were airstrikes and rocket fire after peace talks collapsed earlier this week, the worst of this round of fighting is likely over, as Israel has now withdrawn its ground forces from the strip.
What does Eldar, one of the keenest observers of Hamas in the region, think will happen next?
"Hamas is strong. They have the backing of Gaza," he said. "Israel made many mistakes during the campaign. The lost the support of the international community.
"I don't know what (Israeli Prime Minister) Benjamin Netanyahu will do but Israel must now compromise with Hamas and open the blockade."
He continued: "It's bad for the people of Gaza. For them, it's a sign Israel understands only force. Hamas succeeded by terror, by threats, by launching rockets at Israel."
He said Hamas had become more militant since its military struggle to take control of Gaza completely, when the group's military wing "took over", he said.
Hamas has social welfare, political and military wings. The leader of the political wing, Khaled Mashal, represents Hamas internationally from exile in Qatar, and is nominally Hamas' overall leader.
The social welfare wing administers Gaza and funds its social services.
The military wing is led by Mohammed Dief, who operates from Gaza and whose wife and son were killed this week in an Israeli airstrike reportedly targeting him.
Hamas' battle with local rival Fatah over Gaza followed its victory in the 2006 elections for the Palestinian National Authority (PNA), in which it won the largest share of seats. But after the war, Russia, US, UN and European Union refused to continue providing funding to the PNA unless Hamas formally recognised Israel's right to exist and renounced violence, which it refused to do.
Story continues beneath slideshow
Tensions between Fatah and Hamas culminated in a brief war in Gaza that Hamas won, effectively dividing the Palestinian territories between the Fatah-ruled West Bank and Hamas-ruled Gaza.
Prof Hollis says Hamas could have become "less of an enemy" if it had been able to take its place in the Palestinian government: "I interviewed members of Hamas after they were elected in 2006. It's fair to say they were untested in power. Naive but they could have been far less of an enemy if their election had been recognised. But that opportunity was lost."
The two groups gradually reconciled in the intervening years and their decision to form a unity government in June this year, combined with Israel's failure to destroy Hamas militarily, show it should be allowed a place at the table, Prof Hollis said.
"What that government did was create the potential for Hamas to be part of the future and in the discussion about the Palestinian territories," she told HuffPost UK.
"Unless Hamas is part of the future, conceded some role in the future running of the Gaza Strip, and there is a lifting of the blockade, Hamas will fight on - confident that the Israelis know that for them to re-occupy the Gaza Strip and/or fight house to house in Gaza, would take a very heavy toll on Israeli soldiers and ultimately will not work.
"They (Israel) will not get a definitive solution to the problem they identify with Hamas by military means."
Chris Doyle, the director of the London-based Council For Arab And British Understanding (CAABU), said another factor could make Israel keener to deal with Hamas.
He said despite the country's tough rhetoric against them, many of its leaders fear its support shifting to "more militant" groups, such as Islamic Jihad, a group whose influence in Gaza has grown recently with Iranian backing.
He pointed out that flags of the Islamic State, whose brutal militants are carring out beheadings and crucifixions as they tear through Syria and Iraq, have been recently spotted in Gaza.
He added the lifting of the blockade of the territory was "common sense".
He told HuffPost UK: "The blockade needs to be lifted. It's just political common sense. Hamas should not get any of the credit for this just because they are in power."
When asked whether he thought Hamas had "won" in Gaza, Mr Doyle said: "I'm reluctant to talk in terms of 'winning' in all of this."
Suggested For You
SUBSCRIBE AND FOLLOW
Get top stories and blog posts emailed to me each day. Newsletters may offer personalized content or advertisements.Learn more