Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python!! I am trying to find a stop codon within a string of DNA 1.) run down the string If there is no stop codon

Python!!

I am trying to find a stop codon within a string of DNA

1.) run down the string

If there is no stop codon return "no stop"

if there is a codon return the index of the first letter of the codon

(stop codons are ATG, TAA, and TAG)

This is my code so far but I doesnt print anything:

def stopping():

myDNA = input("Enter a string of DNA: ")

for j in myDNA:

j = 0

thisCodon = myDNA[j: j+3]

stop = ((thisCodon == 'TAA') or (thisCodon == 'TAG') or (thisCodon == 'TGA'))

while j <= j-3 and not stop:

hasStop = False

j = j + 1

print("-1")

if thisCodon == stop:

hasStop = True

return myDNA[j]

Run these two strands through the code:

TTTAAAGGGAAA (no stop codon)

TTTAAATAGGGG (stop codon at index 6]

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Database Concepts International Edition

Authors: David M. Kroenke

6th Edition International Edition

0133098222, 978-0133098228

Students also viewed these Databases questions

Question

Why does sin 2x + cos2x =1 ?

Answered: 1 week ago

Question

What are DNA and RNA and what is the difference between them?

Answered: 1 week ago

Question

Why do living creatures die? Can it be proved that they are reborn?

Answered: 1 week ago

Question

What is the Definition for Third Normal Form?

Answered: 1 week ago

Question

Provide two examples of a One-To-Many relationship.

Answered: 1 week ago