Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Doubt in usage of join function

by davido (Cardinal)
on Jan 07, 2019 at 15:52 UTC ( [id://1228149]=note: print w/replies, xml ) Need Help??


in reply to Doubt in usage of join function

Consider reading perlintro, perlop, and perldata for a better understanding of creating lists, populating arrays, and using quote-like constructs. If ":", "$string\n", and "$string2\n" create strings, then "1,2,3,4,5" must also do so. And therefore if double quotes are used for creating strings, the double-quote operator must NOT be for creating lists. You instead wanted:

my @input = (1, 2, 3, 4, 5);

Dave

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others imbibing at the Monastery: (9)
As of 2024-04-26 08:53 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found