Proverbs 21:11 in the World English Bible
When the mocker is punished, the simple gains wisdom. When the wise is instructed, he receives knowledge.
Context
10 The soul of the wicked desireth evil: his neighbour findeth no favour in his eyes.
11 When the scorner is punished, the simple is made wise: and when the wise is instructed, he receiveth knowledge.
12 The righteous man wisely considereth the house of the wicked: but God overthroweth the wicked for their wickedness.