Of course, one key issue is whether the students truly have to use the restroom vs. merely using it as a pretext to leave the classroom. Even when the breaks are legitimate, I believe it's incumbent on the departing student to do so in as unobtrusive a way as possible so as not to disrupt the proceedings, just as one would do so for a movie or a concert. (Via Obscure Store.)