Masturbation refers to pleasing oneself by stimulating the genitalia. This is a sin many Christians suffer from especially those who are single. I have seen it stated on the internet and other places that masturbation might not be sinful, but I believe that it certainly is, because one needs to concentrate on someone in order to reach orgasm. This concentration or looking at un-tasteful material is basically lusting, which in itself is a sin.
Masturbation also has a number of side-effects
The question however remains, how to prevent masturbation?
This can only be done by decreasing your lustful nature through avoiding things which causes you to lust.
Examples include trying to avoid lusting after the opposite sex while walking the streets as young ladies are dressing more and more inappropriately and nothing is left to the imagination anymore.
Another great way to prevent masturbation, is to be careful of the things you take in from the television set. There is a plot to destroy the things of God, and therefore one can not watch the simplest of television programmes without seeing a couple making out, which will cause you to lust. If you are to study the plot of the programme in most instances the sex scene does not really add anything to the plot.
Even with these two suggestions your thoughts will still be seeded with lust, and you will need to arrest these thoughts as they manifest, and rebuke them. You will soon come to the point where you will realize that lust has no power over you once you make a concerted effort to avoid it.