(50G) Partition of Integer N in M Parts - Printable Version +- HP Forums (https://www.hpmuseum.org/forum) +-- Forum: HP Software Libraries (/forum-10.html) +--- Forum: General Software Library (/forum-13.html) +--- Thread: (50G) Partition of Integer N in M Parts (/thread-7007.html) |
(50G) Partition of Integer N in M Parts - Gerald H - 10-09-2016 02:47 PM For stack N M both positive integers the programme returns the number of partitions of N into at most M parts. For more info see https://en.wikipedia.org/wiki/Partition_(number_theory) eg For input 30 19 the programme returns 5465 in 3.9 seconds. Code:
|