Following from my previous question, it seems that APL performs a scanl in O(n^2) but the compiler is smart enough to optimize for simple primitives. What then is the best strategy to apply \
to non-simple functions? Additionally, there are many cases when the right associativity does affect the result, for example:
{0⌈⍺+⍵} \ 3 ¯4 1 5 ¯1 ¯2 ¯3 2 0 4 ⍝ 3 0 3 5 4 5 5 5 5 5
Which is not the answer I would have expected 3 0 1 6 5 3 0 2 2 6