Young people should avoid promiscuity. In order to be able to protect their chastity, they should strengthen their hearts against the raging desire of the flesh by reading and meditating on the psalms and the Word of God. If you feel the flame, take a psalm or one or two chapters of the Bible, and read. When the flame has subsided, then pray. If it is not immediately checked, you should bear it patiently and courageously for one, two, or more years and persist in prayer. But if you can no longer endure and overcome the burning desires of the flesh, ask the Lord to give you a wife with whom you may live in a pleasing manner and in true love. I myself have seen many people who gave free rein to their passions and fell into detestable lusts. But in the end they had to endure woeful punishments; or if on a blind impulse they were fixing their minds on marriage, they got wives who were not at all suited and obedient. This, of course, served them right.
Luther’s works, vol. 4: Lectures on Genesis: Chapters 21-25 p 334-335