Proverbs 19:25 in the King James Version
Smite a scorner, and the simple will beware: and reprove one that hath understanding, and he will understand knowledge.
Context
24 The sluggard buries his hand in the dish; he will not so much as bring it to his mouth again.
25 Flog a scoffer, and the simple will learn prudence; rebuke one who has understanding, and he will gain knowledge.
26 He who robs his father and drives away his mother is a son who causes shame and brings reproach.