Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

(Golf as well): List of Partitions

by jynx (Priest)
on May 06, 2001 at 10:49 UTC ( #78334=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    sub P {
    # This is so that we don't go off the deep end with recursion : )
    ...
             map({ [$_[0], @$_] } P($_[1]))
       }
    }
    
  2. or download this
    5
    4 1
    ...
    2 1 1 1
    1 1 1 1 1
    And many duplicates (which i handle seperately)
    
  3. or download this
    sub u{map{[split//,$_]}sort{$b cmp$a}keys%{{map{my$t=join'',@$_;$t=>1}
    +@_}}}
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others imbibing at the Monastery: (10)
As of 2015-07-07 12:55 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (88 votes), past polls