It is really difficult to prevent the kids from watching TV when the elderly at home loves to which those TV programmes. Is it possible to buy a TV and put it in your mum's room? If possible you can have some other activities with your kids in the living room.
Also, it is important to explain to the kids the meaning of those "foul" words and how rude they are. Also what kind of people used those words and at what occasions. At least they know such words should be prohibited in some occasions. But for your kid at such age, the best way is to prevent them from contacting such conversation.
I personally think that scolding is not the best way to teach children because frankly speaking whenever we scold our child we would easily lose temper and the tone would likely be bad. They would just learn from us and think that this is the way to solve problemts. Explaining, though it is time-consuming, would have a better effect in a long time. They would also learn that discussion is the way to put forward ideas.