Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

(ar0n) Re (2): Removing empty string elements from an Array

by ar0n (Priest)
on Nov 13, 2001 at 07:44 UTC ( [id://124993]=note: print w/replies, xml ) Need Help??


in reply to Re: Removing empty string elements from an Array
in thread Removing empty string elements from an Array

Taking that one step further, if by "empty" you also mean lines that consist solely of whitespace:
@array = grep /\S/, @array;

[ ar0n ]

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (3)
As of 2024-03-29 02:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found