Pascal's triangle: Difference between revisions
m
→Functional Python
(→{{header|Python}}: Added functional derivations of both finite and non finite lists of pascal rows.) |
|||
Line 4,142:
showPascal(
take(7)(
infinitePascalRows()
)
)
Line 4,197:
# scanl is like reduce, but returns a succession of
# intermediate values, building from the left.
# scanl :: (b -> a -> b) -> b -> [a] -> [b]
def scanl(f):
|