Playing around with the code, and ran into a syntax error


Hey guys, I was just playing around with the code but I can't figure out how to add an exclamation mark after the name, when I try to, it just gives me a syntax error. How would I add one?

var greeting = function (name) {
    console.log("Hey there,"+" "+name);


Help would be appreciated.




console.log("Hey there, "+ name + "!");

not work?


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