Steps in overcoming masturbation
Be assured that you can be cured of your difficulty. Many have been, both male and female, and you can be also if you determine that it must be so. This determination is the first step. That is where we begin. You must decide that you will end this practice, and when you make that decision, the problem will be greatly reduced at once. But it must be more than a hope or a wish, more than knowing that it is good for you. It must be actually a DECISION. If you truly make up your mind that you will be cured, then you will have the strength to resist any tendencies which you may have and any temptations which may come to you.
After you have made this decision, then observe the following specific guidelines: They may not be bliblical but practical steps to overcome masturbation.

A Guide to Self-Control:

1. Never touch the intimate parts of your body except during normal toilet processes.

2. Avoid being alone as much as possible. Find good company and stay in this good company.

3. If you are associated with other persons having this same problem, YOU MUST BREAK OFF THEIR FRIENDSHIP. Never associate with other people having the same weakness. Don’t suppose that two of you will quit together, you never will. You must get away from people of that kind. Just to be in their presence will keep your problem foremost in your mind. The problem must be taken OUT OF YOUR MIND for that is where it really exists. Your mind must be on other and more wholesome things.
.
4. When you bathe, do not admire yourself in a mirror. Never stay in the bath more than five or six minutes — just long enough to bathe and dry and dress AND THEN GET OUT OF THE BATHROOM into a room where you will have some member of your family present.
.
5. When in bed, if that is where you have your problem for the most part, dress yourself for the night so securely that you cannot easily touch your vital parts, and so that it would be difficult and time consuming for you to remove those clothes. By the time you started to remove protective clothing you would have sufficiently controlled your thinking that the temptation would leave you.
.
6. If the temptation seems overpowering while you are in bed, GET OUT OF BED AND GO INTO THE KITCHEN AND FIX YOURSELF A SNACK, even if it is in the middle of the night, and even if you are not hungry, and despite your fears of gaining weight. The purpose behind this suggestion is that you GET YOUR MIND ON SOMETHING ELSE. You are the subject of your thoughts, so to speak.
.
7. Never read pornographic material. Never read about your problem. Keep it out of mind. Remember — “First a thought, then an act.” The thought pattern must be changed. You must not allow this problem to remain in your mid. When you accomplish that, you soon will be free of the act.
.
8. Put wholesome thoughts into your mind at all times. Read good books — Church books — Scriptures — Sermons of the Brethern [sic, Cistern too?]. Make a daily habit of reading at least one chapter of Scripture, preferably from one of the four Gospels in the New Testament, or the Book of Mormon. The four Gospels — Matthew, Mark, Luke and John — above anything else in the Bible can be helpful because of their uplifting qualities.
.
9. Pray. But when you pray, don’t pray about this problem, for that will tend to keep [it] in your mind more than ever. Pray for faith, pray for understanding of the Scriptures, pray for the Missionaries, the General Authorities, your friends, your families, BUT KEEP THE PROBLEM OUT OF YOUR MIND BY NOT MENTIONING IT EVER — NOT IN CONVERSATION WITH OTHERS, NOT IN YOUR PRAYERS. KEEP IT OUT of your mind!
.
The attitude of a person toward his problem has an affect on how easy it is to overcome. It is essential that a firm commitment be made to control the habit. As a person understands his reasons for the behavior, and is sensitive to the conditions or situations that may trigger a desire for the act, he develops the power to control it.

For more tips, see Steps in overcoming Masturbation – Part 2