RosettaCodeData/Task/Partition-function-P/Haskell/partition-function-p-2.hs
2025-02-27 18:35:13 -05:00

2 lines
90 B
Haskell

part = 1 : b 1
where b n = p where p = zipWith (+) (1 : b (n + 1)) (replicate n 0 ++ p)