7. Keeps popping up an error message?


#1

I'm trying to get this to work but it keeps popping up with an error message and I can't figure out what's wrong...

var newNumber = twoTimes(8); {
console.log(newNumber);
};

Is there anything wrong with this code?


#2

Its suppose to be like this:

var timesTwo= function(number)
{
 return number*2;   
};
var newNumber=timesTwo(5);
console.log(newNumber);

#3

Ok thanks. This really helps...


#4

LOL thats what i did and it said it wouldnt work until now....ugh