(Luke Sharrett/Bloomberg News)

President Trump is known to eat lots of fast food: McDonald’s and Kentucky Fried Chicken rank among his favorites. But the new president doesn’t just like the taste of Quarter Pounders and Fish Delights — he has also said that he believes chain establishments are safer.

Speaking at a Republican town hall last year, Trump praised Wendy’s and McDonald’s for maintaining what he called “a certain standard”: “I like cleanliness,” he said, “and I think you're better off going there than maybe some place that you have no idea where the food is coming from.”

He’s right. Chain restaurants do often demonstrate better food safety practices than their non-chain competition. And that’s important, given the number of people who come down with food-borne illnesses each year: The Centers for Disease Control and Prevention puts the figure at 48 million.

This is not a universal rule, of course. Your corner dive could follow food-safety protocol to the letter, and your local Starbucks could be a dump. But generally speaking, public health experts have found, major corporate chains have consolidated and standardized their food prep operations in a way that cuts down on possible contamination.

“Chains are worried about their corporate reputations. They have a lot to lose,” said Donald Schaffner, an extension specialist in food science at Rutgers University. “It’s not that mom-and-pop places don’t have a lot to lose, but they may lack that corporate infrastructure to make sure their food is safe.”

A 2013 poll of restaurant managers in eight states, conducted by a division of the CDC, found that chain restaurants were more likely to check the temperature of hamburgers and to have a certified food manager on staff, both measures that can stem the spread of pathogens such as E. coli and norovirus. When the CDC surveyed managers and workers in six states a year later, they found that the managers of chain restaurants and large restaurants were much more likely to pass a basic food safety test.

Just last week, researchers at the University of Pennsylvania published an analysis of two years of health inspection data from Philadelphia area restaurants, looking for patterns among the restaurants that flunked. Their conclusion?

“Health departments and city inspection officials could use these findings to focus their efforts on non-chain restaurants” -- which saw 9.6 total violations per inspection, vs. 6.5 in their chain counterparts.

The chain advantage begins with suppliers, said Juelene Beck, a former vice president at Burger King who now works as a consultant. Because chain restaurants frequently comprise a supplier’s entire business, they have an unusual degree of control over how their products are sourced and handled. In the past 10 years, Beck said, most national chains have hired third-party food safety consultants to conduct random audits of the facilities that supply burgers, buns and other ingredients to their establishments.

That’s significant, since many outbreaks originate in the supply chain: the great Taco Bell E. coli outbreak of 2006 was traced to shredded lettuce.

Chains have also centralized more prep in these facilities — the better to minimize employee error at the point of sale. Fresh produce is frequently not chopped at the franchise location, but at a central facility where it can be tested for microbes, for instance. And many chains cook burgers and other foods from frozen, which is basically a means of making sure beef doesn’t sit at unsafe temperatures. At McDonald’s, the grill tops won’t release until a burger has been on the heat for a certain number of minutes.

“They’ve engineered human frailty out of the system,” Schaffner said.

But food safety advocates point out that mistakes still happen — either because not every company adheres to equally high standards, or because it’s next to impossible to guarantee compliance across hundreds of suppliers and thousands of employees. And when mistakes do happen, the size of the chain and the concentration of its suppliers can make the results deadly.

“There are too many exceptions that prove the rule,” said Marion Nestle, an expert on nutrition and food safety, in an email to The Post. “The issues in restaurant food safety are ensuring a safe supply chain, following basic food safety rules (hot foods hot, cold foods cold, no cross contamination, etc.), and keeping employees healthy and washing their hands. Violations of those principles can occur anywhere, and do.”

The most infamous chain restaurant outbreak occurred in a string of Pacific Northwestern Jack in the Boxes in 1993. Six children died, and 171 people required hospitalization, as a result of an E. coli strain traced back to undercooked beef patties.

“A lot of people changed a lot of things after that,” said Beck, who served as an expert witness in one of the resulting lawsuits. “There was an immense response from suppliers and [other restaurants]. Safety became a cornerstone issue.”

More recently, the fast-casual chain Chipotle suffered repeat outbreaks of E. coli, salmonella and norovirus, sickening more than 500 people in the second half of 2015. While federal investigators weren’t able to identify the cause of every individual outbreak, one was attributed to salmonella-infected tomatoes, and two were pinned on sick front-of-house employees.

No national chains have seen outbreaks in the past year — at least none that rose to the attention of CDC. But four regional and midsize chains have suffered incidents of food-borne illnesses, all of which were traced back to supplier facilities.

In Hawaii, Genki Sushi was briefly closed for selling scallops infected with hepatitis A; several Virginia locations of Tropical Smoothie Cafe also found the virus in imported strawberries. In Western New York, Mighty Taco discovered a bacteria in its refried beans. In Ohio, the ice cream maker Jeni’s — which has 20 scoop shops and also sells in grocery stores — has twice found listeria in its factories.

“Every restaurant poses a potential risk,” Schaffner said. “It’s not whether a place is a fast-food chain or not — it’s what programs they have in place [to prevent contamination].”

Unfortunately, Schaffner points out, few consumers can readily evaluate what’s going on behind the scenes of their favorite restaurant. In the absence of that knowledge, we can trust a big brand to safeguard our food … or check its last inspection from the local health department.

A word of warning to Trump: The McDonald’s nearest the White House was faulted for significant violations on its most recent report. There are, however, several independent restaurants in the neighborhood that passed their inspections with flying colors.

More from Wonkblog:

You should never eat cookie dough — period.

Is organic food safer and healthier? The guy in charge of U.S. organics won’t say.

Why you might want to be skeptical of McDonald’s latest food changes