Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Strange bevahiour of grep function.

by LanX (Canon)
on May 14, 2013 at 15:57 UTC ( #1033514=note: print w/ replies, xml ) Need Help??


in reply to Strange bevahiour of grep function.

Hard to read, but if you want to invert a logical clause you also have to switch and to or and invert all sub-clauses.

see De_Morgan's_laws

And consider to use List::MoreUtils 'any' instead of grep.

HTH =)

Cheers Rolf

( addicted to the Perl Programming Language)

update

s/ List::Util / List::MoreUtils /


Comment on Re: Strange bevahiour of grep function.
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (7)
As of 2014-08-22 05:12 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (147 votes), past polls