Doubt in code


#1


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


Oops, try again. It looks like you didn't define orangeCost.


Replace this line with your code. 
var orange= function orangeCost(price)
{
    var cost=price*5 
    console.log(cost);
}


orange(5)

what is my mistake in this code?


#2

take a look at 3. function syntax, your function syntax is slightly off


#3

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