This is a city familiar with pain.

But what happened just after 10:30 p.m. on Monday presented a new and inexplicable horror the likes of which Manchester had never before seen: carnage inflicted by one of its own. Salman Abedi, 22, was born and bred in Manchester, the son of Libyan parents who reportedly came to Britain to escape the Gaddafi regime.

For many, there is no question that the traditional working-class stronghold will survive the latest attack with the same dogged resilience it has always shown. But in a city where community and diversity are particular points of pride, the revelation that a Manchester native was the perpetrator of the deadliest attack on British soil in more than a decade has proved a mystifying reality.

“The issue of Manchester recovering is not in question,” said Jim Bonworth, a retired chief inspector in the Greater Manchester Police, who was on the scene when Provisional Irish Republican Army militants set off a truck bomb in the city center in 1996. “But why a 22-year-old man who was born in Manchester would want to undertake this exercise, goodness only knows.”

Fate has not always been kind to Manchester.

In the 19th century, the Industrial Revolution transformed the place with rapid speed into a modern city whose prosperity ultimately depended on factories with long hours and brutal conditions. In World War II, much of that industrial juggernaut — known for its symbol, the worker bee — was reduced to rubble, destroyed by Nazi air raids.

The decades that followed were characterized by considerable economic hardship, and even by other bombings that long preceded this one. Terrorism is a familiar concept in Manchester: When IRA militants detonated the truck bomb in 1996, they injured more than 200 and ruined millions of dollars in public infrastructure.

In none of those instances, however, did the locals lose their resolve. Despite the circumstances, officials are hoping this time will be no different.

In remarks that followed the devastating news, Andy Burnham, Manchester’s mayor and a member of the Labour Party, was quick to emphasize the city’s ties that bind, which were on display in a Tuesday vigil where thousands gathered in the city’s central square to express solidarity with the victims.

The people of Manchester, Burnham said Tuesday, “gave the best possible immediate response to those who seek to divide us.”

“Even in the minute after the attack, they opened their doors to strangers and drove them away from danger,” he said of city’s population, known locally as “Mancunians,” in reference to the city’s Roman past.

Burnham was apparently referring to reports widely circulated in British media of local Muslim taxi drivers who ferried survivors and their family members to and from hospitals free after the attack. One of these drivers, Saf Ismael, told CBS News that seeing the victims was “like seeing my own daughter there.”

But in the aftermath of Monday’s attack, a potential backlash was a concern on the minds of many.

In the Brexit referendum in June 2016, voters in Greater Manchester overwhelmingly opted to remain in the European Union. By contrast, most voters in northern England outside the city voted by significant margins to remove Britain from the multistate bloc, many citing concerns over immigration as a principal motivation.

At the same time, however, Manchester is no stranger to the spike in anti-immigrant hate crimes that followed the referendum. Between July and September 2016, for instance, 1,033 incidents were reported in the area, according to data released by Britain’s Home Office. This figure was second only to that in London, where 3,356 incidents were reported in the same period, according to the data.

The initial signs this week pointed to a manifest goodwill, even as British authorities continued their probe for other accomplices they believed had helped Abedi, and the news broke that Libyan authorities had arrested his father and young brother before the latter could carry out another attack in Tripoli.

A donation page created by the Manchester Evening News, a local newspaper, raised more than one million British pounds ($1.3 million) in the first 24 hours after the attack, and tattoo parlors banded together to offer special deals on the worker bee, the city’s symbol, with proceeds to benefit the families of victims.

“This is kind of a knee-jerk reaction to do something positive, to give to the city in some way,” said Ventnor Brewer, 37, a studio manager at Sacred Art, one of the tattoo parlors involved. “You just want to feel like you’re involved and contribute in some way when something like that happens.”

But locals struggled to come to terms with the realization that Monday’s attack was the work of at least one of their own — and the question of what, if anything, it meant to them.

On Wednesday, Sadiq Patel, 46, was escorting Renee Rachel Black, 93, into the center of town to do her shopping — for, among other things, kosher meat, she said. The two are members of an interfaith council in nearby Blackburn, said Patel, a Muslim, as they were walking arm-in-arm in Manchester’s central square, where city leaders organized an impromptu memorial for the victims.

“As Northerners, we’ll just have to get on with it,” Patel said.

As he spoke, a man approached him in the square, heckling him over an alleged conspiracy to show that Muslims are good people.

Read more:

Brother of Manchester bomber was ‘planning an attack’ in Libya, authorities say

Manchester shows why even the best protection can’t stop attacks

Some in Manchester, and beyond, see the attack as targeting women and girls

Today’s coverage from Post correspondents around the world

Like Washington Post World on Facebook and stay updated on foreign news