News for hackers. Stuff that matters.
Re:Thinking in an Array Language by akavi on Saturday January 13, 2024 @10:16PM (#38987087)
I guess I still fail to see the advantage of this over Haskell:

    dot = (sum.) . zipWith (\*)
    p = [2, 3, 4]
    q = [1, 0, 2]
    p `dot` q
Like, the only difference to my eyes is using names for sum/zipWith, and not having the lifts/restructuring happen "magically"
Re:Thinking in an Array Language by RodgerTheGreat on Saturday January 13, 2024 @11:08PM (#38987354)
The APL/J/K/Klong versions are more general; they all work for a variety of ranks of input, whereas the Haskell version- which is the longest and most visually noisy- bakes in a single rank's mapping explicitly.
Re:Thinking in an Array Language by radiator on Sunday January 14, 2024 @01:23AM (#38988023)
Well, for one, your Haskell version is obviously much longer.
Re:Thinking in an Array Language by dr_kiszonka on Sunday January 14, 2024 @04:06AM (#38988749)
Haha!