With mass shootings in schools, theaters, churches, and workplaces, experts in threat assessment have come up with advice about what to do.

In general, they have settled on a simple guideline: “run, hide, fight.”

This is a grim topic for an advice article, but experts say mass shootings have become so frequent and deadly in the United States that people should think in advance about how they will respond if the worst happens.

The specific situation and location matters. “There is never going to be a universal rule for this,” said Bob Kolasky, an acting deputy undersecretary for the Department of Homeland Security who oversees active shooter training.

The department has published detailed advice, defining an “active shooter” as someone with a gun engaged in killing or trying to kill people in a confined and populated place.