This article has been updated.

October was bookended by tragedy.

On Halloween, a man who authorities say emigrated from Uzbekistan seven years ago, drove a rented pickup truck down a bike path, killing eight people and injuring 11 before being shot and subdued. On Oct. 1, a man shooting from the windows of a hotel on the Las Vegas Strip killed 58 and wounded 546.

It would not be surprising for reactions to those events from a president to vary. The Vegas incident was the deadliest mass shooting in modern American history, killing seven times as many people. But the difference in reactions from President Trump reflects his perceptions of the sorts of threat each perpetrator represents, not the actual damage done.

Immediately after the Vegas shooting, Trump offered one thought on Twitter.

Several days later, he visited the city, offering his support for first responders and those who had been wounded by the spray of bullets.

Stephen Paddock, the shooter, used a device called a bump stock to increase the rapidity of his shots. In the days that followed the massacre, there was a push to curtail bump stocks that earned the support of even some members of Trump’s own party and — tepidly — the NRA.

But the White House wasn’t interested in talking about how to address the issue of mass shootings in the hours after the attack. During the White House news briefing the next day, press secretary Sarah Huckabee Sanders was explicit in postponing any discussion of addressing any underlying causes.

“Look, this is an unspeakable tragedy,” she said. “Today is a day for consoling the survivors and mourning those we lost. Our thoughts and prayers are certainly with all of those individuals. There’s a time and place for a political debate, but now is the time to unite as a country.”

“A motive is yet to be determined,” she continued, “and it would be premature for us to discuss policy when we don’t fully know all the facts or what took place last night.”

She did, though, then talk about how gun laws hadn’t prevented a rash of shootings in Chicago, and noted that “one of the things that we don’t want to do is try to create laws that won’t stop these types of things from happening.”

When Trump traveled to Vegas, he rejected out-of-hand any discussion of new policies to limit gun ownership.

“We’re not going to talk about that today,” he said. “We won’t talk about that.”

The national conversation quickly turned to his response to the hurricane in Puerto Rico.

Trump’s response to the attack in New York on Tuesday was immediately different. Since the attack, at about 3 p.m. on Wednesday, Trump has tweeted (as of writing) six times about it and about the need for policy changes to address it.

And so on.

This is not a new pattern for Trump. He’s regularly raced to link terrorist attacks (and things that turned out not to be terrorist attacks) to the need to crack down on immigration. It’s of a piece with his campaign, during which he promoted the risks posed by immigrants as a central concern for the public and his own policies as the only way of addressing them.

Contrasting the two incidents in October mirrors the overall difference between gun violence and terrorism. Since Trump was inaugurated, there have been 283 incidents in the United States in which four or more people were shot. The death toll from those incidents, excluding Vegas, is 224. There have been a handful of terrorist attacks, perhaps only three of which involve a Muslim or an immigrant (though it’s not clear). In those incidents, two people were killed.

Interestingly, Trump describes the perpetrators of the attacks in Vegas and New York in the same language. Paddock was “a sick man, a demented man,” in Trump’s description, as was Sayfullo Saipov, identified by police as the killer in Manhattan.

Trump likely means this in two different senses, though. Paddock was “sick” in the sense that he was mentally broken and nothing could be done to prevent his actions. Saipov was “sick” in that his actions were sick, and his reported allegiance to the Islamic State is what spurred him to that action.

Part of this is rooted in how Trump considers people like Paddock versus how he considers people like Saipov. Saipov’s actions are inseparable from his status as an immigrant, as Trump’s tweets make clear: What he did is a reflection of all immigrants and therefore immigration laws need to change. Paddock — older, white — was just a guy with a broken brain. What can you possibly do about that?

So, with Saipov, Trump is quick to weigh in on policy proposals meant to address the perceived threat posed by immigrants — even if those proposals are not necessarily rooted in an accurate understanding of the issue.

Both Vegas and New York were tragedies and, in both cases, many elected officials will be looking for ways to prevent similar things from happening again. For Trump, though, the events pose dissimilar risks to the American people. One exemplifies the existential threat from radical terrorists that must be addressed. One — the much deadlier one — is just a thing that happens.