The Paris train incident was a near-perfect example of how a determined group of potential victims can turn a terrorists attack into an abject failure. In the account here, several people on the train acted to thwart the shooter and as a group they succeeded.
I remember seeing a TV report of a school here in the U.S. where the principal teaches this mindset to his students with occasional active shooter drills. The shooter is one of the staff, and his weapons are inert dummies but the student response is drilled into the kids and they practice with great gusto.
Street wisdom is that when the weapons come out and you don't have one, one should run from a knife but rush a gun. This principle applies double in say a schoolroom situation where there really isn't anywhere to run. Throw everything that comes to hand and rush the shooter. Bury him under the crush of bodies. Kick him when he's down, after all it's when you get your best leverage.