Prebiotic synthesis of nucleic acids