Implementing pipe in thirteen languages

One small fold keeps every program flat and linear

pipe(x, f, g, h) feeds x to f, the result to g, and that to h. It is h(g(f(x))), read in the order it runs: a flat, linear execution path, written as a single fold over the steps.

Loading the axioms…