Young man, I urge you, “flee sexual immorality” ( 1 Cor. 6:18) if you love life. “Let no one deceive you with empty words, for because of these things the wrath of God comes upon the sons of disobedience” (Eph. 5:6). Flee the occasions of it, – the company of those who draw you into it, – the places where you might be tempted to it. Read what our Lord said about it in Matthew 5:28. Be like holy Job: “Make a covenant with your eyes” (Job 31:1). Flee talking of it. It is one of the things ought not so much as to be named. You cannot handle tar and not be defiled. Flee the thoughts of it: resist them, mortify them, pray against them, – make any sacrifice rather than give way. Imagination is the hotbed where this sin is too often hatched. Guard your thoughts, and there is little fear about your deeds.
– J. C. Ryle, Thoughts for Young Men, pp. 30-31.