in reply to package Func; (any,all,some,and none methods)

It's not particularly obscured, but it looks like a useful mini-module. This seems similar to the quantum entanglement concept, but smaller and no-frills.

It's interesting to use this logic in practice, in that any(1,2,3) != 4 is true (there is at least one non-4 element), while not any(1,2,3) eq 4 is also true (there is no 4 element).

Mind if I use something like it in a much larger project I'm building?

print "There is no spoon" if $oracle->none(qw(neo trinity morpheus)) e +q 'one';

--
[ e d @ h a l l e y . c c ]

Replies are listed 'Best First'.
Re: Re: package Func; (any,all,some,and none methods)
by Gunth (Scribe) on Apr 13, 2004 at 18:18 UTC
    Go for it Agent Smith. My idea came from Quantum::Superpositions, and I thought that a 34kb module with a hint of Damian was a little bit of an overkill for these functions :-) You're right its not very obscured. That was an after thought. You're response also made me think of something: the Matrix had to be written in Perl. I mean, which other language's gliches would result in deja vu?