Error while running the code

Tell us what’s happening:
Describe your issue in detail here.
I have followed the guidelines and concatenated the string but somehow it is throwing an error saying that the string should contain all the words that are assigned to the variables. I have watched the help video as well and everything seems to be ok. Please help me with this.

Your code so far


const myNoun = "dog";
const myAdjective = "big";
const myVerb = "ran";
const myAdverb = "quickly";

// Only change code below this line
const wordBlanks = "His" + " " + myAdjective + " " + myNoun + " " + myVerb + " " + "too " + myAdverb + "towards mouse."// Change this line
// Only change code above this line

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.93 Safari/537.36 Edg/96.0.1054.53

Challenge: Word Blanks

Link to the challenge:

I really wouldn’t call this an error but a failed test.

If you want to see what the test is seeing, you can put:

console.log(wordBlanks);

at the bottom and in the console window in the bottom right it will output your string. If you check that closely you should be able to see the problem and solve it.

You’re just missing a space between “myAdverb” & towards mouse!

This is the corrected code -

redacted

@codingart

It’s great that you are wanting to help out, but please don’t post working solutions - the goal is to help people learn, not give then the answer they can cut and paste in.

Also, it would be better , rather than tell them exactly what is wrong, where possible, to tell them how to figure it out. That is what I was trying to do in my post.

1 Like

@kevinSmith Oops, apologies! I agree with your view, will keep this in mind.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.