Gossip is shallow, busybody, sinfulness. Which just means they need our prayers, not anger. Anger is our normal, survival instinct reaction so don’t feel badly about it. However, we are here to learn how to rise above our lower instincts. Generally, anger is in the same bottom-dwelling, emotional category as gossip.
Jesus recommends not fighting fire with fire, which is what turning the other cheek means. For instance, if someone insults us, instead of raising the ante with anger or delivering another insult, you can say something like: “Ok, you have a point there.” By not giving our opponent anything to grab onto and escalate, we are essentially depriving evil of oxygen. Of course, we should learn to do this out of love, not for the sake of winning.
Therefore, by ignoring their comments, not letting it bother you, praying for their wellbeing and healing, and turning it over to the Holy Spirit, you will be advancing spirituality in the ways of the Lord.
I myself am still learning this and, in your situation, would have reacted less admirably. I would probably have raised my hand and asked the instructor, “Is gossip a sin?” He/she would have replied in the affirmative and I would have responded, “Would you please explain that to the kind ladies over there?”