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

Re: replace separator from array elements

by artist (Parson)
on Sep 12, 2007 at 20:27 UTC ( #638673=note: print w/replies, xml ) Need Help??


in reply to replace separator from array elements

Here is more 'generic' solution.
while(<DATA>){ my ($text,$values) = split ; print "$text $_\n" for split /\,/,$values; } __DATA__ vlan 107 vlan 121 vlan 122,127,129,137 hello 678,123,456
--Artist

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (2)
As of 2022-12-03 23:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?