Greatest subsequential sum: Difference between revisions
m
→{{header|AppleScript}}
m (→{{header|Haskell}}: Added type signature, output, applied hindent, minor tidy) |
|||
Line 89:
=={{header|AppleScript}}==
{{Trans|Haskell}}
Linear derivation of both sum and list, in a single fold:
<lang applescript>-- maxSubseq :: [Int] -> [Int] -> (Int, [Int])
|