Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Re: Re: Re: Re: Re: Useful uses of Quantum::Superpositions?

by feanor_269 (Beadle)
on Apr 09, 2003 at 19:40 UTC ( [id://249382]=note: print w/replies, xml ) Need Help??


in reply to Re: Re: Re: Re: Re: Useful uses of Quantum::Superpositions?
in thread Useful uses of Quantum::Superpositions?

You mean it'll DWIM? Cool... still not sure it's that useful tho...

feanor_269

Replies are listed 'Best First'.
Re: Re: Re: Re: Re: Re: Re: Useful uses of Quantum::Superpositions?
by diotalevi (Canon) on Apr 09, 2003 at 19:46 UTC

    Sure its useful. Over at id:249381 I had to create a short function indexany() for use in the grep. If @searchCriteria were actually a disjunction then this code doesn't require the new function anymore.

    # Without disjunctions sub indexany { -1 != index $_, $_[0] and return 1 for @_[1 .. $#_]; re +turn 0 } @newArray = grep indexany($_, @searchCriteria), @largeArray # With disjunctions $searchCriteria = any( @searchCriteria); @newArray = grep -1 != index($_, $searchCriteria), @largeArray;
Re: Re: Re: Re: Re: Re: Re: Useful uses of Quantum::Superpositions?
by Mr. Muskrat (Canon) on Apr 09, 2003 at 19:46 UTC

    That depends on what you mean ;-)

Log In?
Username:
Password:

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

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

    No recent polls found