Part of the purpose of homework is to encourage the student to revisit the assignment later in the day. Repetition of exercise develops muscles and your brain is a muscle.
That said
Teacher lost her shit
Generally best when teachers manage their own tempers, as hot heads do a poor job of gaining the trust and maintaining the attention of their students.