1

Is there a Mathematica-esque way to apply set of functions in a sequence? IE apply[{f,g,h},x] that produces result equivalent to f@g@h@x

My current workaround

apply[{}, x_] := x;
apply[{f_}, x_] := f@x;
apply[l_, x_] := First[l]@apply[Rest[l], x];
Yaroslav Bulatov
  • 7,793
  • 1
  • 19
  • 44

0 Answers0