Bob Ackerman wrote:
> 
> On Monday, March 4, 2002, at 12:15  PM, John W. Krahn wrote:
> >
> > print +(split //, "abcd")[1], "\n";
> 
> now that is clever! what is the literal meaning/function of the '+'.
> of course, one still must know that a leading paren will be seen by 'print'
>   unless there is some intervening dummy character. that's ok.


perldoc -f print
[snip]
                         Because print takes a LIST,
      anything in the LIST is evaluated in list context,
      and any subroutine that you call will have one or
      more of its expressions evaluated in list context.
      Also be careful not to follow the print keyword
      with a left parenthesis unless you want the corre­
      sponding right parenthesis to terminate the argu­
      ments to the print--interpose a `+' or put paren­
      theses around all the arguments.



John
-- 
use Perl;
program
fulfillment

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to