#!/usr/bin/perl # http://perlmonks.org/?node_id=1146191 use strict; use warnings; my $sequence = 'AATGGTTTCTCCCATCTCTCCATCGGCATAAAAATACAGAATGATCTAACGAA' +; $sequence =~ /(ATG.*?(?:TAG|TAA|TGA))(??{print "$1\n"})/;
which prints:
ATGGTTTCTCCCATCTCTCCATCGGCATAA ATGGTTTCTCCCATCTCTCCATCGGCATAAAAATACAGAATGA ATGGTTTCTCCCATCTCTCCATCGGCATAAAAATACAGAATGATCTAA ATGATCTAA
In reply to Re: Print A Sequence with Start codon and different Stop Codon
by Anonymous Monk
in thread Print A Sequence with Start codon and different Stop Codon
by PerlKc
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |