Monads/List monad: Difference between revisions
Content added Content deleted
(→{{header|AppleScript}}: Updated primitives) |
|||
Line 37: | Line 37: | ||
-- TEST ------------------------------------------------------------------------ |
-- TEST ------------------------------------------------------------------------ |
||
on run |
on run |
||
-- |
-- Pythagorean triples drawn from integers in the range [1..n] |
||
-- |
-- {(x, y, z) | x <- [1..n], y <- [x+1..n], z <- [y+1..n], (x^2 + y^2 = z^2)} |
||
pythagoreanTriples(25) |
pythagoreanTriples(25) |