Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: How can we interpolate an expression??

by ww (Archbishop)
on Sep 20, 2012 at 18:51 UTC ( #994730=note: print w/replies, xml ) Need Help??


in reply to How can we interpolate an expression??

... as a one-liner; nothing else here is new, other than escaping the variables to avoid interpolation.

C:\>perl -E "my $num1=3; my $num2=4; say \"The result of \$num1 * \$nu +m2 is: \" . $num1*$num2;" The result of $num1 * $num2 is: 12

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://994730]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (8)
As of 2017-11-23 15:05 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:













    Results (336 votes). Check out past polls.

    Notices?