Re: Can explain the MAP function more clearly? Thanks
- From: Eric Schwartz <emschwar@xxxxxxxxx>
- Date: Wed, 28 Sep 2005 09:39:19 -0600
Tad McClellan <tadmc@xxxxxxxxxxxxxx> writes:
> yezi <ye_line@xxxxxxxxxxx> wrote:
>> what is {$_=> 1 } mean?
>
>
> It means the same as
>
> {$_, 1 }
Every now and then I learn something new about Perl that is so basic.
I had mentally tagged => as "quote LHS, and then act as comma"; your
comment prompted me to look up perlop, which said,
If the argument on the left is not a word, it is first
interpreted as an expression, and then the string value
of that is used.
It's always nice when I can learn something new about something I
thought I understood already.
-=Eric
.
- References:
- Can explain the MAP function more clearly? Thanks
- From: yezi
- Re: Can explain the MAP function more clearly? Thanks
- From: Tad McClellan
- Can explain the MAP function more clearly? Thanks
- Prev by Date: Re: Use of hash variables in module call - puzzling behaviour
- Next by Date: Re: Perl time and Mysql time
- Previous by thread: Re: Can explain the MAP function more clearly? Thanks
- Next by thread: Re: Can explain the MAP function more clearly? Thanks
- Index(es):
Relevant Pages
|