Question: acids = { ' UUU ' : { ' 1 - letter': ' F ' , ' 3 - letter': 'Phe', 'amino acid': 'Phenylalanine' }

acids={'UUU': {'1-letter': 'F','3-letter': 'Phe', 'amino acid': 'Phenylalanine'}}
{'UUC': {'1-letter': 'F','3-letter': 'Phe', 'amino acid': 'Phenylalanine'}}
{'UUA': {'1-letter': 'L','3-letter': 'Leu', 'amino acid': 'Leucine'}}
{'UUG': {'1-letter': 'L','3-letter': 'Leu', 'amino acid': 'Leucine'}}
......
{'GGG': {'1-letter': 'G','3-letter': 'Gly', 'amino acid': 'Glycine'}}
# create an empty string variable called 'protein
# Find the index of the 'AUG' substring in the mrna variable from Part 3
start_codon= mrna.find('AUG')
# create a loop counter variable that starts at this index
index= start_codon
# Create a 'while' loop to iterate while the loop counter is less than the length of the mrna string
while index< len(mrna):
# Using the loop counter as the index into the mrna string, grab the next triplet (mrna[idx:idx+3]) and store in a variable called 'triplet'
triplet= mrna[index:index+3]
# Using this 'triplet' string variable as a key, look up the '1-letter' protein associated with it using the acids dictionary-----HELP here
# If this is equal to 'X', break out of the loop
# if not, add this letter to the protein string
# Add 3 to the counter variable
index +=3

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!