Language: JAVA Script
write a function called 'dynamicAdder (num). The dynamicAdder function will return a new function that will allow us to create new separate customadding functions.
Look below to see how this function is invoked:
const addTwo = dynamicAdder (2); // returns a functionconsole.log(addTwo (5)); // 7
const addTen = dynamicAdder (10); // returns a functionconsole.log(adden(5)); // 15
const addNinety= dynamicAdder (90); // returns a functionconsole.log(addNinety (5)); // 95
*********************************************************/
function dynamicAdder(num) {|// Your code here}
/****DO NOT MODIFY ANYTHING UNDER THIS LINE****/
try{| module.exports = dynamicAdder;}catch (e) {|module.exports=null;}
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here