On Jan 23, 2008 2:17 PM, Gunnar Hjalmarsson <[EMAIL PROTECTED]> wrote:
> Bryan R Harris wrote:
> > Is there any way to change the last statement to do what I want, which in
> > this case is print "perl is cool"?
> >
> > **
> > $a='$b is cool';
> >
> > ... bunch o
using http://www.unix.org.ua/orelly/perl/advprog/ch05_01.htm
maybe it helps
#!/usr/bin/perl
$t=' "$tt is cool\n"';
$tt="perl";
print eval $t;
thanks regards
#
2008/1/23, Bryan R Harris <[EMAIL PROTECTED]>:
>
>
>
> >> Is there any way to change the last statement to do what I want, which
> in
>
Bryan R Harris wrote:
Is there any way to change the last statement to do what I want, which in
this case is print "perl is cool"?
**
$a='$b is cool';
... bunch of stuff here...
$b = "perl";
print $a, "\n";'
print eval qq("$a"), "\n";
--
Gunnar Hjalm
>> Is there any way to change the last statement to do what I want, which in
>> this case is print "perl is cool"?
[stuff cut out]
> (my $new_message = $message) =~ s/\$(\w+)/$includes{$1}/g;
[stuff cut out]
Um, I guess... I was more curious if there wasn't something like:
print "\S$b
On Jan 23, 2008 10:04 AM, Bryan R Harris <[EMAIL PROTECTED]> wrote:
> Is there any way to change the last statement to do what I want, which in
> this case is print "perl is cool"?
Is this the kind of thing you're looking for?
#!/usr/bin/perl
use strict;
use warnings;
my $messa
Is there any way to change the last statement to do what I want, which in
this case is print "perl is cool"?
**
$a='$b is cool';
... bunch of stuff here...
$b = "perl";
print $a, "\n";'
**
Thanks!
- Bryan
--
To uns