Tell us what’s happening:
**Your code so far**
function wordBlanks(myNoun, myAdjective, myVerb, myAdverb) {
var result = “”;
// Your code below this line
var a = "My ";
var b = "and furry ";
var c = "to the store ";
result = “a” + “myAdjective” + “b” + “myNoun” + “myVerb” + “c” + “myAdverb”;
I get the word blanks forming the string. I don't get these two results:
wordBlanks("dog", "big", "ran", "quickly") should contain all of the passed in words separated by non-word characters (and any additional words in your madlib).
wordBlanks("cat", "little", "hit", "slowly") should contain all of the passed in words separated by non-word characters (and any additional words in your madlib).
I am finding a lot of these challenges poorly worded and confusing, and would have no idea to use "return result"; as indicated in the forum. Also, I don't know why the other word blanks like cat and little are there for testing, nor where they should go in the exercise. I really want to learn to code and to stick with FreeCodeCamp vs. CodeAcademy. However, the people who create the challenges really need to be a lot more clear, so I don't know how to get that feedback to the right people. As for the challenge itself, any help would be appreciated.
// Your code above this line
return result;
}
// Change the words here to test your function
wordBlanks("dog", "big", "ran", "quickly");
Your browser information:
Your Browser User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13) AppleWebKit/604.1.38 (KHTML, like Gecko) Version/11.0 Safari/604.1.38
.
Link to the challenge: