President Obama from Warsaw on Friday weighed in on the fatal shootings of five police officers and wounding of seven more, as well as of two civilians, by saying the attack was inexcusable, unjustified and tragic – but then suggested easy access to weapons was at least partly to blame.

He first expressed outrage and condolences.

"There's no possible justification for these kinds of attacks or any attack on law enforcement," Obama said, CNN reported. "Anybody involved will be held accountable."

The 'Stop Hillary' campaign is on fire! Join the surging response to this theme: 'Clinton for prosecution, not president'

TRENDING: Undercover journalist turns the tables, sues Planned Parenthood for defamation

NBC News reported he also said: "I believe I speak for every single American when I say that we are horrified over these events and that we stand united with the people and the police department in Dallas."

He offered condolences to the Dallas mayor about what he characterized as a "vicious, despicable and calculated attack on law enforcement." And he indicated members of the FBI were on scene to help out with the investigation.

Obama then waded into gun-control territory, suggesting if only Americans didn't have such easy access to firearms, then incidents like Dallas wouldn't occur.

"When people are armed with powerful weapons, unfortunately it makes it more deadly and more tragic, and in the days ahead we are going to have to consider those realities as well," he said, Politico reported.

Obama's comments came from Warsaw, where he's attending a summit with NATO leaders.

This was Obama's second address from Warsaw.

Just a few hours earlier, he commented on the two police shootings of black men earlier this week, both reported by WND, and called on the nation to try to recognize buried biases that need to be "rooted out," CNN said.

"If communities are mistrustful of the police, that makes those law enforcement officers who are doing a great job, who are doing the right thing, that makes their lives harder," Obama said, in his first public address from Warsaw. "When people say 'black lives matter,' it doesn't mean that blue lives don't matter. But right now, the data shows that black folks are more vulnerable to these kinds of incidents. There is a particular burden that is being placed on a group of our fellow citizens."

Donald Trump, meanwhile, went a different path and put out a statement that expressed sorrow for the victims, but called for a return to "law and order" and less divisiveness.

"We must restore law and order. We must restore the confidence of our people to be safe and secure in their homes and on the street," he said.

Trump then spoke of the earlier "senseless, tragic deaths of two motorists" in Baton Rouge and Minnesota, and offered "thoughts and prayers" for all the victims' families.

"We pray for our brave police officers and first responders who risk their lives to protect us every single day," he went on. "Our nation has become too divided. Too many Americans feel like they've lost hope. Crime is harming too many citizens. Racial tensions have gotten worse, not better. This isn't the American Dream we all want for our children. This is a time, perhaps more than ever, for strong leadership, love and compassion. We will pull through these tragedies."

The motives for the Dallas shootings aren't yet clear. As WND reported, the suspect who died during the attack was named Micah X. Johnson, a 25-year-old Dallas-area resident who wanted simply to kill white people. Early reports listed him as an Army veteran who served in the Reserve, angered by recent police shootings, but with no prior criminal record or ties to terrorism, Heavy.com reported. He did tell officers during a stand-off, however, the "end is coming" and his intent was to "kill more" police, the Dallas mayor said.

The attack started late Thursday evening, when several snipers shot and killed five police officers in Dallas, and injured seven others. Initial reports were that five officers were killed and six injured. But on Friday, the Dallas mayor told CNN that five officers were killed, another seven injured, and that two civilians had been hurt in the attack as well. The fatalities and injuries came in a series of coordinated attacks that came at the end of peaceful protest of fatal officer shootings of black men in Baton Rouge and in Minnesota, as WND reported.

Dallas Area Rapid Transit tweeted that four of its officers had been shot. The agency identified one of its dead as officer Brent Thompson, age 43.

Three other suspects were taken into custody, but their names have not been released. One of the suspects is reportedly a woman. And police, early Friday, were still warning residents to be on high alert.

"We still don't have a complete comfort level that we have all the suspects," said Dallas Police Chief David Brown, NBC News reported.

Like the reporting you see here? Sign up for free news alerts from WND.com, America's independent news network.

The city on Friday was on lockdown while bomb units swept for devices and explosives. The Federal Aviation Administration, meanwhile, ordered a temporary no-fly restriction over the city.

Brown described the attack on the officers an "ambush-style" shooting.

"We believe that these suspects were positioning themselves in a way to triangulate on these officers from two different perches in garages in the downtown area, and planned to injure and kill as many law enforcement officers as they could," he said, noting some of the police officers were shot in the back.