News for hackers. Stuff that matters.
Re:What if you couldn’t program with loops? by uryga on Monday July 15, 2019 @07:07AM (#20439640)
> Processing eg consecutive elements is often annoying

the only place i saw a higher-order function for this is the K language with its `eachpair` combinator (spelled `':` iirc). i wonder why it isn't more common!

(though in Haskell i'd just stick a `tails` somewhere to turn `[a,b,c]` into `[[a,b,c],[b,c],[c],[]]` and map over that)

There are no comments on this comment yet.