Transcribing DNA into RNA
in Study / Rosalind on Rosalind problem
A problem from rosalind “Bioinformatics Stronghold” category
Rosalind Problem Link- Description
- Given DNA coding sequence, we should deduce the sequence of mRNA produced from this DNA sequence
- Input example : AGGCCTTAGGCAGT
- Output example : AGGCCUUAGGCAGU
Biological Background
- DNA sequences consist of 4 bases (A, C, G, T)
- RNA sequences consist of 4 bases (A, C, G, U)
- DNA consists of 2 strands
- coding sequence : has same sequences with mRNA having information except T (should be changed to U)
- noncoding sequence : complement version of coding sequence (A ↔ T, G ↔ C)
My Solution
DNA_seq = input()
RNA_seq = ""
for i in range(len(DNA_seq)):
symbol = DNA_seq[i]
if symbol == 'T':
RNA_seq += 'U'
else:
RNA_seq += symbol
print(RNA_seq)
- just change T to U