Getting problem, it says that i didnot print the value of newNumber variable


#1


https://www.codecademy.com/en/courses/javascript-beginner-en-6LzGd/1/2?curriculum_id=506324b3a7dffd00020bf661


it showing error that i didnt print value of newNumber


// Parameter is a number, and we do math with that parameter
var timesTwo = function(number) {
    return number * 2;
};

// Call timesTwo here!
var newNumber = timesTwo ("5"); 
console.log(newNumber);


#2

on your function call:

var newNumber = timesTwo ("5");

you should pass 5 as integer, no string (Remove the quotation marks)


#3

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