const pipe = (...fns) => x => fns.reduce((v, f) => f(v), x);
const trim = s => s.trim();
const toLower = s => s.toLowerCase();
const process = pipe(trim, toLower);
process(' Hello '); // 'hello'Pipe functions to build a clean data-transformation pipeline.
Chain three functions together using pipe.
Challenge: Use pipe to compose three functions: add2(x), square(x), and subtract10(x) in that order.