Beefy Boxes and Bandwidth Generously Provided by pair Networks
We don't bite newbies here... much
 
PerlMonks  

Re: nested combinations: algorithm advice?

by Pragma (Scribe)
on Sep 23, 2004 at 05:19 UTC ( #393131=note: print w/replies, xml ) Need Help??


in reply to nested combinations: algorithm advice?

#!/usr/bin/perl -lanF_ "@F"=~$r[$_-1]&&print"$.,$_"for 1..@r;$_="{@F}.+{@F}";y/ /,/;push@r,jo +in'|',glob

Replies are listed 'Best First'.
Re^2: nested combinations: algorithm advice?
by Jasper (Chaplain) on Sep 23, 2004 at 09:44 UTC
    #!/usr/bin/perl -lapF_ for$p(@p){$;.="$_ and $p "if 1<grep"@F"=~$_,split/_/,$p}push@p,$_}{$_=$
      What?! No glob? Bah! Ameteur... :-)

      ps. I believe you are missing a semicolon.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (6)
As of 2020-09-23 09:26 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    If at first I donít succeed, I Ö










    Results (130 votes). Check out past polls.

    Notices?