in reply to Re: Write to and read from scalar
in thread Write to and read from scalar
GrandFather,
I did it this way from your example. I would not have known how to do this, but the disk file is basically a representation of the scalar.
my $str = "Hello World\n"; open my $fIn, '<', \$str; my $inStr = <$fIn>; close $fIn; print $inStr;
Is there a reason to use file I/O to the scalar?
Thank you
"Well done is better than well said." - Benjamin Franklin
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Write to and read from scalar
by GrandFather (Saint) on Mar 23, 2012 at 22:56 UTC |