[Who has reached] complete Teshuvah? A person who confronts the same situation in which he sinned when he has the potential to commit [the sin again], and, nevertheless, abstains and does not commit it because of his Teshuvah alone and not because of fear or a lack of strength.
For example, a person engaged in illicit sexual relations with a woman. Afterwards, they met in privacy, in the same country, while his love for her and physical power still persisted, and nevertheless, he abstained and did not transgress. This is a complete Baal-Teshuvah. This was implied by King Solomon in his statement [Ecclesiastes 12:1] "Remember your Creator in the days of your youth, [before the bad days come and the years draw near when you will say: `I have no desire for them.'"]
If he does not repent until his old age, at a time when he is incapable of doing what he did before, even though this is not a high level of repentance, he is a Baal-Teshuvah.
Even if he transgressed throughout his entire life and repented on the day of his death and died in repentance, all his sins are forgiven as [Ecclesiastes, op. cit.:2] continues: "Before the sun, the light, the moon, or the stars are darkened and the clouds return after the rain..." - This refers to the day of death. Thus, we can infer that if one remembers his Creator and repents before he dies, he is forgiven.