In a somewhat unhinged press conference, National Rifle Association head Wayne LaPierre argued that instead of regulating guns better we should have a police officer in every school. He suggested we could pay for it by cutting foreign aid.
According to the National Center for Education Statistics there are 98,817 K-12 schools in the United States. The Bureau of Labor Statistics says cops make $55,000 a year. So we could put $5.4 billion as the low level estimate of the cost. Cops obviously have health care benefits and pension and disability benefits for police offers tend to be fairly costly so the real price would be higher than that.
At any rate, on both the policing side and the gun control side it would be a mistake to focus too much on spectacular school massacres. What happened at Sandy Hook was terrible, but at least 78 people have been shot and killed in America since then. If you want to regulate guns more strictly, the smart play is to focus on the portable concealable handguns that are widely used in those "ordinary" crimes and if you want to spend billions on hiring new police officers the smart play to focus on deploying them in the high-crime neighborhoods where most of the murdering happens. Obviously one would hope that a less-armed, lower-crime society would also feature fewer monstrous massacres as a side benefit but concentrating our policing resources on static defense of K-12 schools would be foolish.