Given the amino acid sequence of a polypeptide - Phe, Val, Asn, Gln, His, Leu, Cys, Gly, Ser - perform the following tasks with a Perl program:1. Define an array that contains the amino acids in the...

1 answer below »
Given the amino acid sequence of a polypeptide - Phe, Val, Asn, Gln, His, Leu, Cys, Gly, Ser - perform the following tasks with a Perl program:1. Define an array that contains the amino acids in the right order (use the three letters notation, as above). Print it in one line (without a foreach loop).2. Determine the number of amino acids in the polypeptide and print it.3. Add the amino acid "His" to the end of the polypeptide (use the "push" function). Print the resulting array in one line (without a foreach loop).4. Create a "mutation": replace "Gly" with "Asp". Print the resulting array.5. Ask the user to enter a number between 1 and the number of amino acids in the polypeptide, and print the amino acid in that position (e.g. if the user enters "4" the program should print "Gln".)6. Create an inversion: get two positions in the sequence from the user and invert the sequence of the amino acids between them. For example, if the user enters 3 and then 6, the program should replace Asn, Gln, His, Leu with Leu, His, Gln, Asn. (Using "array slices" and the "reverse" function). Print the result.7. Create a string that will contain the amino acid sequence of the resulting polypeptide, in the format Phe-Val-Asn... (use string concatenation inside a foreach loop. Make sure not to leave a "-" before the first amino acid or after the last one). Print that string.
Answered 13 days AfterSep 19, 2021

Answer To: Given the amino acid sequence of a polypeptide - Phe, Val, Asn, Gln, His, Leu, Cys, Gly, Ser -...

Arun Shankar answered on Oct 03 2021
134 Votes
=begin
Q1) Create and then print the array without using a foreach loop
=end
=cut
@arr = ("Phe"
, "Val", "Asn", "Gln", "His", "Leu", "Cys", "Gly", "Ser");
print "@arr\n";
=begin
Q2) Create and then print the array without using a foreach loop
=end
=cut
$size = @arr;
print "Number of amino acids = $size\n";
=begin
Q3) Add the amino acid "His" to the end of the polypeptide (use the "push" function).
=end
=cut
push(@arr, ("His"));
print...
SOLUTION.PDF

Answer To This Question Is Available To Download

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here