If a teacher flipped out screaming like that at all at my school, they'd lose their job faster than... stuff.
Our chemistry teacher did it when a boy swore in class.
The teacher is a foul man, and swear a lot, etc, but the school cannot afford to lose him as he has ensured that they won the state chemistry prize for years now.
That boy swore when he got his test mark at the beginning of class, and then the teacher raged. He yelled at the kid for being foul, and basically insulted him regarding his effort for about 40 mins.
Then let us go. We were terrified.