Untitled
Anonymous
plain_text
09/23/2024 5:56 PM
520 B
21
Indexable
#1. Print a DNA sequence that could be in upper and lower caps into a new sequence that is in upper caps only
#a
seq=input("Enter a new DNA sequence")
seq2=''
for i in range(len(seq)):
if seq[i]=='a':
seq2=seq2+'A'
elif seq[i]=='t':
seq2=seq2+'T'
elif seq[i]=='c':
seq2=seq2+'C'
elif seq[i]=='g':
seq2=seq2+'G'
else:
seq2=seq2+seq[i]
print(seq2)Editor is loading...
Leave a Comment