What happened when the teacher walks out of the classroom to do something?

Ik. It was entertaining watching the class turn into chaos, the students getting away with it and then the waking in and us all pretending nothing happened.