Question: Write a function expression assigned to the variable madLib that takes five parameters: 1. adjective-A string adjective. Ex: lazy 2. adverb-A string adverb. Ex: quietly'

Write a function expression assigned to the variable madLib that takes five parameters: 1. adjective-A string adjective. Ex: "lazy 2. adverb-A string adverb. Ex: "quietly' 3. noun1-A string noun. Ex: "dog 4. noun2-A string noun. Ex: "moon 5. verb-A string verb. Ex: "smashed The function should return a mad lib string value by substituting the parameter values into the following template The adjective nounl adverb verb the noun2 1 /The lazy dog quietly smashed the moon. 2 //console.logCmadLibC"lazy","quietly", "dog""moon", "smashed")); Run JavaScript Reset code
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
