Flexibility of nucleic acids: From DNA to RNA