Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery

Re: interpolating operators within strings

by NetWallah (Abbot)
on Apr 14, 2013 at 01:34 UTC ( #1028582=note: print w/ replies, xml ) Need Help??

in reply to interpolating operators within strings

Try using "eval" : see "perldoc -f eval".

my $a = eval "2 $_ 2";
This is not considered "safe" because it is possible to inject unwanted code into the eval string.
It is fine for testing purposes.

             "I'm fairly sure if they took porn off the Internet, there'd only be one website left, and it'd be called 'Bring Back the Porn!'"
        -- Dr. Cox, Scrubs

Comment on Re: interpolating operators within strings
Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (6)
As of 2015-11-26 17:19 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (704 votes), past polls