BAGHDAD, Iraq — Throughout Iraq, fear gave way to defiance Sunday as voters, even in the most volatile areas, cast ballots in landmark parliamentary elections that militants tried their best to disrupt with dozens of explosions that shook Baghdad even before the polls opened.
By the end of the day, at least 38 people were dead and more than 80 were wounded throughout the country, Iraqi authorities said, including 25 casualties in a Baghdad apartment building that collapsed on sleeping families in an early-morning blast.
The despair at the scenes of violence stood in stark contrast to triumphant moments that unfolded elsewhere as Iraqis dipped their fingers in purple ink and cast ballots in elections that were billed as the first organized and secured by Iraqis since the U.S.-led invasion of 2003.
"It's in the Iraqi nature to rise to a challenge, and we were challenged," said Younis Gomar, the head of a polling center in Baghdad.
"We mourn the tragic loss of life today, and honor the courage and resilience of the Iraqi people who once again defied threats to advance their democracy," President Obama said in a statement of congratulations.
Later, speaking in the White House Rose Garden, Obama added that by the end of August, "our combat mission will end" and said, "By the end of next year, all U.S. troops will be out of Iraq."
The U.S. military, however, played a crucial behind-the-scenes role Sunday, a fact that calls into question whether Iraq's security forces will be able to lock down their country on similar high-stakes occasions after the American withdrawal.
After months of joint planning with Iraqis, American attack helicopters provided air support; American drones supplied aerial intelligence; American teams provided route clearance and escorts for international monitors, and American forensics experts investigated explosives found near polling stations.
With election day out of the way, Iraqis now face what could be an even more gargantuan task. None of the top vote-getters is expected to win an outright majority, ensuring weeks and probably months of horse-trading before a new government is formed.
Analysts and foreign diplomats agree that the coalitions most likely to win are the self-proclaimed nationalist slate led by Iraq's incumbent Prime Minister Nouri al-Maliki, a Shiite Muslim; the secular, mixed-sect ticket of former premier Ayad Allawi; and an alliance of Iranian-backed Shiite candidates and religious parties that was widely predicted to trail the first two in all but the most conservative Shiite parts of the country.
Once again, however, Kurdish parties in semi-autonomous northern Iraq are likely to hold the balance of power because Arab parties will need their support to assemble a majority in the 325-seat Iraqi parliament.
Reliable information on Sunday's results and voter turnout isn't expected for at least another day, possibly longer, according to the United Nations mission in Iraq. That didn't stop various candidates or their representatives from claiming victory on television or publicly hinting at electoral fraud, perhaps in efforts to position them for battle in case they didn't fare well.
It will take Iraqi election officials days to compile allegations of fraud or irregularities, but among the most common violations cited Sunday were candidates campaigning in polling centers, heads of households voting for other family members, and security forces intimidating voters to pick specific candidates.
In the southern Shiite holy city of Najaf, some 3,000 residents didn't find their names on the voter rolls, said the province's Gov. Adnan al-Zurfi, who called it "a breach of law." Similar complaints emerged in the Kurdish city of Suleimaniyah, as well as the ethnically diverse city of Kirkuk, where Sunni Arabs and Sunni Kurds are battling.
At least 5,000 internally displaced people — Iraqis who were forced from their homes in the sectarian bloodshed of recent years — didn't find their names registered in Diyala province, according to the election commission there. Tens of thousands of displaced Iraqis needed special permission to vote outside their home provinces.
"It was a fierce battle with the Iraqi people on one side and all the other powers on the other, and the Iraqi people came out victorious. By all other powers, I mean the establishment, the bureaucracy, the insurgents, the incompetents," said Mohannad al-Kinani, the head of Ayn al-Iraq, an independent Iraqi group that monitored the elections. "The Iraqi people have shown that they are strong and not easily subjugated, and that they know what they want.... It is time for the occupation to pack its bags and leave."