Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re^2: If you believe in Lists in Scalar Context, Clap your Hands

by tilly (Archbishop)
on Oct 23, 2008 at 21:30 UTC ( #719173=note: print w/ replies, xml ) Need Help??


in reply to Re: If you believe in Lists in Scalar Context, Clap your Hands
in thread If you believe in Lists in Scalar Context, Clap your Hands

Oh really?

my @stuff = ("this", "that", "and", "the", "other", "thing")[0, 1, 5];
It looks like I just sliced a list.
print "Hello " . ("earthlings", "world");
It looks like I just put a list in scalar context.

However I agree that you can't do the other things you said you can't do without constructing something other than a list. Furthermore I'm the kind of person who never thought much of semantic arguments. I don't care what you call the construct, as long as you understand what it does.


Comment on Re^2: If you believe in Lists in Scalar Context, Clap your Hands
Select or Download Code
Replies are listed 'Best First'.
Re^3: If you believe in Lists in Scalar Context, Clap your Hands
by Anonymous Monk on Oct 24, 2008 at 12:30 UTC
    Quick! Bandaid that bleeding list! :p

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://719173]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (17)
As of 2015-07-29 16:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (265 votes), past polls