Mian-Chowla sequence: Difference between revisions
m
→{{header|Haskell}}
m (→{{header|REXX}}: optimized a compound statement.) |
|||
Line 779:
------------------- MIAN-CHOWLA SEQUENCE -----------------
mianChowlas :: Int -> [Int]
mianChowlas =
Line 788 ⟶ 787:
(foldr insert sumSet ((2 * m) : fmap (m +) mcs), m : mcs)
where
valid x =
m = until valid succ n
|