Beefy Boxes and Bandwidth Generously Provided by pair Networks
Problems? Is your data what you think it is?
 
PerlMonks  

Re^2: map array elements with single quotes

by karthigayan (Initiate)
on Mar 10, 2010 at 09:07 UTC ( [id://827726]=note: print w/replies, xml ) Need Help??


in reply to Re: map array elements with single quotes
in thread map array elements with single quotes

This node falls below the community's threshold of quality. You may see it by logging in.

Replies are listed 'Best First'.
Re^3: map array elements with single quotes
by almut (Canon) on Mar 10, 2010 at 09:52 UTC

    First of all, it would've been more appropriate for you to respond to the original post, not to ikegami's reply — he didn't use map the wrong way :)

    Next, while your observation is correct, you seem to have overlooked the fact that the original poster is getting an unwanted trailing comma.

    Your solution could be fixed by changing the output field separator $,

    ... $, = ","; print @foo;

    or (to keep the effect localized)

    ... { local $, = ","; print @foo; }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (5)
As of 2024-04-19 02:07 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found