You will write three small functions that read an mRNA and judge a mutation. The genetic code is already in the program as the table TABLE. A stop codon is written as *.
The idea. Read the codons in groups of three. A silent change keeps the amino acid. A nonsense change makes a stop codon. A shift of the frame happens when the number of bases inserted or deleted is not a multiple of 3.
Your tasks.
translate. It gives the amino acids of an mRNA as a string of letters, and it stops at the first stop codon.classify. It gives "silent", "missense" or "nonsense" for a codon that changes into another.frame_kept. It says whether inserting (positive) or deleting (negative) a number of bases keeps the reading frame.Have you tried it?
Do the tasks in the editor first, and run the checker after each one. Its hints help when a check fails. When you are ready, compare your code with this solution.
Log in to join the discussion.
Loading…
With Standard, you also open 12 more problems, 2 Python labs and 1 extra course. Everything you have used here stays free, always.