I’m supposed to ‘Inside the takeOrder function, set orderCount equal to orderCount plus 1, so that each time the takeOrder function runs, 1 is added to the orderCount.’, but this code looks okay. Buuut it doesn’t work.
The error returns: Did you add one to the orderCount whenever the takeOrder function runs?
var orderCount = 0;
function takeOrder(topping, crustType) {
console.log(“Order: “+crustType+” pizza topped with “+topping+””);
orderCount += 1;
}
takeOrder(“pepperoni”, “thin crust”);
takeOrder(“pep”, “thick crust”);
takeOrder(“wtf”, “ba’al”);
I actually finished the Javascript course before discovering that this course exists, but went back to cover new material.