People were having virtual sex long before the computer was invented. Almost two thousand years ago Jesus Christ said concerning this question: "You have heard that it was said to the ancients, "You shall not commit adultery." But I say to you that whoever looks on a woman to lust after her has already committed adultery with her in his heart" (The Bible, New Testament, the Gospel of Matthew, chapter 5, verses 27-28). In a word, you may be quite a respectable family man and not jump into bed with somebody else's wife. But the Son of God, estimating man's righteousness, raises moral standards up to the heavenly level. The smallest, thoroughly covered lewdness exists in your heart - and God, for Whom all the most secret thoughts and feelings are revealed, classifies it as a sin.
When reading books, watching movies, travelling the Internet, a person can, so to say, commit adultery virtually, that is, commit sin. But the Word of God warns: "...The wages of sin is death, - and points out to the way of salvation, - but the gift of God is eternal life through Jesus Christ our Lord" (The Bible, New Testament, the Epistle to the Romans, chapter 6, verse 23).