(CNN)The questions seem to come up almost every time a crime occurs where the perpetrator is of a different race, religion or ethnicity than the victims: Is it a hate crime? Is it an act of terror? Why are some violent acts labeled hate crimes or terrorism and others not? And does it even really matter?
When is a crime a hate crime and when is it terrorism?
This week's shooting in Fresno, California, seemed like an open-and-shut case of a hate crime. Police said a 39-year-old black man, Kori Ali Muhammad, shot and killed three white men at random. Muhammad allegedly put up social media posts where he expressed a dislike for white people and made statements to officers that made police "believe it is a hate crime."
So how does law enforcement make the determination?
The FBI says a crime becomes a hate crime when there's an added element of bias. For example, if the victim was killed because of his or her race, religion or sexual orientation.
"Hate crimes are different from other crimes. They strike at the heart of one's identity," FBI Director James Comey said in a speech at the Anti-Defamation League National Leadership Summit in 2014. "They strike at our sense of self, our sense of belonging. The end result is loss: loss of trust, loss of dignity and, in the worst case, loss of life."
They're motivated by bias, said David Stacy, government affairs director of the Human Rights Campaign.
"In a hate crime, the victim is targeted because of his characteristics," Stacy said. "These are bias-motivated crimes, and often they are much more violent than traditional crimes."
In 2015, three Muslims were shot to death by a white neighbor in an apartment near the University of North Carolina at Chapel Hill campus. The victims' families were convinced that race and religion played a primary factor in those tragedies.
But CNN legal analyst Danny Cevallos said law enforcement needs more than that to call something a hate crime. They need to prove that racial or religious hatred factored into the motive for the crime.
"Typically in criminal law, motive is not an element of a criminal offense," Cevallos said. "However, motive can be evidence of your intent (to commit a crime). Why you did something can tell us about what you meant to do when it happened. Hate crimes require that (an intent to commit crime) be motivated by some animus, some hatred of other people."
That's why it may have been an easier call for police in Fresno to label the shootings there a hate crime, because it can be argued that Muhammad's alleged social media postings espousing hatred for whites speaks to his motivations for carrying out the crimes.
In the North Carolina case, on the other hand, police investigation seemed to indicate the slayings were sparked by a parking dispute, and not the students' religion.
In March, a white man named James Harris Jackson stabbed to death a black man in New York and said he did so as a "practice" run for more killings. Jackson was charged with murder in the second degree as a hate crime.
But Jackson also faces a terrorism charge in the case -- murder as an act of terrorism in the first and second degrees. So what about this case makes it a terrorist act?
The world has never really settled on standard definition of 'terrorism,' but the US Code of Federal Regulations defines it as "the unlawful use of force and violence against persons or property to intimidate or coerce a government, the civilian population, or any segment thereof, in furtherance of political or social objectives."
Once again, it all comes down to motive. Was there a political or ideological agenda behind the attack?
In the New York case, law enforcement thought so. According to police, Jackson, a Baltimore resident, said he traveled to New York because it is the media capital of the world and he wanted to make a statement.
That was enough to convince the Manhattan District Attorney that Jackson should be charged with terrorism.
"James Jackson prowled the streets of New York for three days in search of a black person to assassinate in order to launch a campaign of terrorism against our Manhattan community and the values we celebrate," he said.
In many cases, the attacks, at first glance, seem like they should be labeled terrorism. But they're not.
In the Fresno shootings, Muhammad yelled "Allahu Akbar" (the Arabic phrase translates to "God is greatest"), but police don't believe the attacks are terrorist acts. They have yet to explain why.
"Based on the information that we have been provided and our investigation has shown, is that this is solely based on race," Fresno Police Chief Jerry Dyer said. "It has nothing to do with terrorism, in spite of the statements he made."
Think back to Dylann Roof and the killing of nine people at historically black Emanuel African Methodist Episcopal Church in June 2015. Roof, a white supremacist, said he killed the nine attendees of a Bible study at the church because he wanted to start a race war. He was convicted of hate crimes and sentenced to death, but never charged with terrorism.
That's despite an outcry from many who said what Roof did was, in their eyes, the textbook definition of terrorism. In an CNN Digital opinion piece, CNN National Security Analyst Peter Bergen wondered what the US would have called the attack if Roof had been a Muslim.
"But do the thought experiment: If this attack on the church in Charleston had been conducted by a Muslim man shouting 'Allahu Akbar,' what is already a big news story would have become even bigger, as it would appear to fit so well into the political and media narrative that Muslim militants are the major terrorist problem in the United States," Bergen writes.
His comments get at what some observers have been saying for years -- some acts of violence are only labeled terrorism if the attacker is dark-skinned and Muslim.
"There's a danger that we only use the word 'terrorism' to refer to a particular racial profile of perpetrator," said Andrew Mumford with the Center for Conflict, Security and Terrorism. "The Charleston example is a really important one ... Sometimes (the label) terrorism is not used when the nationality of the perpetrator does not fit conventional stereotypes."
There are legal distinctions to calling an act of violence a hate crime or terrorism.
Labeling something a "hate crime" can make the law come down much harder on a defendant. It adds a new serious charge that can come with a heavy additional sentence.
In 2013, a Mississippi judge sentenced Deryl Dedmon -- a white man who killed James Craig Anderson, an African-American, in a clearly racist attack -- to two concurrent life terms.
He and friends had expressly set out for a night of targeted hassling of black people, screaming racial insults and yelling, "White power."
Though it's the states that try hate crimes as a rule, federal authorities can push forward their investigation and prosecution.
Take Dedmon's example. He caught the wrath of the federal government as well. He was sentenced to 50 years in a federal prison.
Labeling something as terrorism has legal ramifications, too, and is not applied lightly.
Federal officials work with a very specific definition of when something is an act of domestic terrorism.
It has to have three characteristics: an act that takes place in the United States, that's dangerous to human life, and is intended to intimidate civilians or affect government policy by "mass destruction, assassination or kidnapping."
Probably the best example is the Fort Hood shooting in 2009. To the victims at the Texas base, it was an act of terror, when Maj. Nidal Hassan opened fire on his fellow service members.
But federal authorities never used the terrorism label. It met some of the criteria, but it was a legal move. Avoiding the label made it easier for them to pursue the death penalty.
At the end of the day, does it really matter if something is or isn't labeled a hate crime or an act of terror? The pain and anguish felt by the survivors of such violence and the victims' families is just as unbearable ... no matter what you call it.