Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: (Golf) RNA Genetic Code Translator

by japhy (Canon)
on Jul 06, 2001 at 00:48 UTC ( [id://94274]=note: print w/replies, xml ) Need Help??


in reply to (Golf) RNA Genetic Code Translator

Are you asking us to golf the entire function, or just the substitution part? Here's a small savings:
sub RNA { # hash here $_=pop;s/..?.?/$g{$&}/g;$_ }
The hash will take me some more time. I'll do that later.

japhy -- Perl and Regex Hacker

Replies are listed 'Best First'.
Re^2: (Golf) RNA Genetic Code Translator
by tadman (Prior) on Jul 06, 2001 at 00:56 UTC
    When I saw that there was already a reply I figured someone pulled a use RNA out of their back pocket.

    The reference function has the hash in it, so yes, any compatible one would also have to, though presumably in a more compact format, which you could obtain by using the reference function hash as input data. Saves typing it in yourself and all that.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others admiring the Monastery: (5)
As of 2024-04-24 10:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found