Proverbs 21:11

21:11 When a scorner is punished, the naive becomes wise;

when a wise person is instructed, he gains knowledge.

Deuteronomy 13:11

13:11 Thus all Israel will hear and be afraid; no longer will they continue to do evil like this among you.

Deuteronomy 21:21

21:21 Then all the men of his city must stone him to death. In this way you will purge out wickedness from among you, and all Israel will hear about it and be afraid.