<?xml version='1.0'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:georss="http://www.georss.org/georss" xmlns:atom="http://www.w3.org/2005/Atom" >
<channel>
	<title><![CDATA[BOL: Concatenate two given sequences, and find the length of the new sequence and also print out the second codon of the sequence]]></title>
	<link>https://bioinformaticsonline.com/snippets/view/42186/concatenate-two-given-sequences-and-find-the-length-of-the-new-sequence-and-also-print-out-the-second-codon-of-the-sequence?</link>
	<atom:link href="https://bioinformaticsonline.com/snippets/view/42186/concatenate-two-given-sequences-and-find-the-length-of-the-new-sequence-and-also-print-out-the-second-codon-of-the-sequence?" rel="self" type="application/rss+xml" />
	<description><![CDATA[]]></description>
	
	<item>
	<guid isPermaLink="true">https://bioinformaticsonline.com/snippets/view/42186/concatenate-two-given-sequences-and-find-the-length-of-the-new-sequence-and-also-print-out-the-second-codon-of-the-sequence</guid>
	<pubDate>Thu, 03 Sep 2020 06:47:43 -0500</pubDate>
	<link>https://bioinformaticsonline.com/snippets/view/42186/concatenate-two-given-sequences-and-find-the-length-of-the-new-sequence-and-also-print-out-the-second-codon-of-the-sequence</link>
	<title><![CDATA[Concatenate two given sequences, and find the length of the new sequence and also print out the second codon of the sequence]]></title>
	<description><![CDATA[<code>#!/usr/bin/perl
use strict;
use warnings;

#assign strings to variables
my $DNA = &quot;GATTACACAT&quot;;
my $polyA = &quot;AAAA&quot;;

#concatenate two strings
my $modifiedDNA = $DNA.$polyA;

#calculate the length of $modifiedDNA and
#print out the value of the variable and its length
my $DNAlength = length($modifiedDNA);
print &quot;Modified DNA: $modifiedDNA has length $DNAlength\n&quot;;

#extract the second codon in $modifiedDNA
my $codon = substr($modifiedDNA,3,3);
print &quot;Second codon is $codon\n&quot;;</code>]]></description>
	<dc:creator>Nishi Singh</dc:creator>
</item>

</channel>
</rss>