Perlで与えたDNAの塩基配列をRNAの塩基配列に変更する。

$ vim 110301.pl

a

  1 use strict;
  2 use warnings;
  3
  4 #The DNA
  5 my $DNA = 'ACGGGAGGACGGGAAAATTACTACGGCATTAGC';
  6
  7 # Print the DNA onto the screen
  8 print "Here is  the starting DNA : \n\n";
  9
 10 print"$DNA\n\n";
 11
 12 #Transcribe the DNA to RNA by substituting all T's with U's.
 13 my $RNA = $DNA;
 14
 15 $RNA =~ s/T/U/g;
 16
 17 #Print the RNA onto the screen
 18 print "Here is the result of transcribing the DNA to RNA : \n\n";
 19
 20 print"$RNA\n";
 21

Esc


$ perl 110301.pl



Here is  the starting DNA :

ACGGGAGGACGGGAAAATTACTACGGCATTAGC

Here is the result of transcribing the DNA to RNA :

ACGGGAGGACGGGAAAAUUACUACGGCAUUAGC