Question: What will be compose function here? Thank you // let's say you have some pretty procedural functions function superCamelCase(s) { returns .split() .map((c, i) =>

What will be compose function here? Thank you
// let's say you have some pretty procedural functions function superCamelCase(s) { returns .split("") .map((c, i) => (i % 2 == 0 ? c. toUpperCase() : c.toLowerCase())) .join("") } function spaceText(s) { return s.split("").join(" ") } function addStyle(s) { return "w" + S + "we" } // you want to make a playlist of them const aestheticFmt Pipeline = compose superCamelCase, spaceText, addStyle ) console.log(aestheticFmtPipeline("hello world")) // won Hello WORLD
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
