11 help me please


#1

var nameString = function (name) {
return("Hi, I am" + " " + name);
};
console.log(nameString("John"));

it says "TypeError: console.log is not a function"

what am i doing wrong?


#2

Try to declare another variable , (var newName for example) that will holds nameString() function then call yournameString() by passing it your name

var newName = nameString("John");
console.log(newName);

#3

If you're interested what it is now you can empty your page and post console.log on the last line, the default echo should show you it's value (or nothing if undefined). To fix the problem refresh the page that will recover the built-in functionality of console.log.


#4

not working........................... :frowning: