According to About.com, two functions of nucleic acids are passing genetic information to the new generations (new cells within an organism or offspring) and coding in protein synthesis. As Wikipedia explains, the first is carried out by deoxyribonucleic acid, or DNA, while protein synthesis is regulated by ribonucleic acid, or RNA.
Both DNA and RNA are nucleotide polymers, with sugar and phosphate groups as a backbone. Under the effect of external or physiological mutagens (substances that can change or damage the structure of DNA), genetic information stored in DNA is altered, Wikipedia explains. When the amount of damage surpasses the DNA’s ability to self-repair, the mutations lead to the synthesis of less effective or even completely defective proteins, which leads to aging and disease development.