Paul wrote:
I am assigned the output of a function to a variable.
my$variable = (function);
print "$variable\n";
The output is:
text
0
So I try this:
chop my$variable = (function);
print "$variable\n";
The output is:
text
*** this is blank space output *****
So it get's rid of the "0", but outputs a new line.
I try double chopping with same results.
How can I finally get rid of it, I just want the text output. Ugh.
Something like
$variable = s/\n.*//s;
should do the trick, which removes the first newline character and
everything following it.
Rob
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/