Question 5


#1

Can someone please tell me whats wrong with this, I am trying to debugg it

var greeting = function(name) {
console.log("greeting" + " " name);
};
greeting("Perez")


#2

console.log("greeting" + " "   name);
                             ^

You're forgetting something there! I hope this helps!


#3

Thanks! I got it! it worked


#4

output "SyntaxError: Unexpected token var"

my answer is from line 10 and I still get a "problem with a syntax pop up"

// Nicely written function:
var calculate = function (number) {
var val = number * 10;
console.log(val);
};

// Badly written function with syntax errors!

greeting var func{name}(console.log(name)))}
var greeting = function (name) {
console.log("Haribol prabhu" + " " + name);
};
greeting("Krsna");