Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid
 
PerlMonks  

Re^3: Powerset short-circuit optimization

by ikegami (Pope)
on Oct 03, 2006 at 23:29 UTC ( #576205=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
       local *_r = sub {
          my @v = @_;
    ...
             _r(@v_) if not $seen{join $;, @v_}++;
          }
       };
    
  2. or download this
    my ($u_set1, $u_set2, $common) = extract_common($set1, $set2);
    my $psetc = powerset($common);
    my $pset1 = product($psetc, powerset($u_set1));
    my $pset2 = product($psetc, powerset($u_set2));
    my $pset = union($pset1, $pset2);
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (5)
As of 2020-10-25 14:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My favourite web site is:












    Results (249 votes). Check out past polls.

    Notices?