Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re^2: Understanding a portion on the Perlretut

by BlueStarry (Novice)
on Dec 09, 2015 at 13:26 UTC ( [id://1149756]=note: print w/replies, xml ) Need Help??


in reply to Re: Understanding a portion on the Perlretut
in thread Understanding a portion on the Perlretut

There is no such sentence on the explanation.
  • Comment on Re^2: Understanding a portion on the Perlretut

Replies are listed 'Best First'.
Re^3: Understanding a portion on the Perlretut
by Corion (Patriarch) on Dec 09, 2015 at 13:33 UTC

    I linked to perlretut. Going there, I find:

    The naive regexp

    ...

    doesn't work; it may match a TGA , but there is no guarantee that the match is aligned with codon boundaries, e.g., the substring GTT GAA gives a match. A better solution is

    while ($dna =~ /(\w\w\w)*?TGA/g) { # note the minimal *? print "Got a TGA stop codon at position ", pos $dna, "\n"; }
    which prints
    Got a TGA stop codon at position 18 Got a TGA stop codon at position 23
    Position 18 is good, but position 23 is bogus. What happened?

    Maybe it was too obvious for me, but a Codon is a nucleotide triplet.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1149756]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others rifling through the Monastery: (6)
As of 2024-04-19 11:32 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found