0

I'm not sure what's wrong, any help? (I'm a beginner, bear with me here)

I'm trying to figure out the problem document.write("Calculator!") setTimeout(function(){ var userNum = prompt("What is your first number?") }, 1000); setTimeout(function(){ var userOp = prompt("What would you like your operation to be? + - * /") }, 1001); setTimeout(function(){ var userNum2 = prompt("Pick your second number") }, 1002); if (userOp === +){ var addNum = userNum + userNum2 document.write("Your answer is" + addNum); } else{ }

12th Nov 2016, 7:17 PM
Ebonee Davis
Ebonee Davis - avatar
5 Respostas
+ 3
It's probably because you try to add two numbers and then pront them, where they should be a string.
12th Nov 2016, 7:45 PM
Keto Z
Keto Z - avatar
+ 2
What is your issue?
12th Nov 2016, 7:39 PM
Keto Z
Keto Z - avatar
0
it says "unexpected token ) on line 11"
12th Nov 2016, 7:42 PM
Ebonee Davis
Ebonee Davis - avatar
0
I didn't finish the If/else statement yet
12th Nov 2016, 7:42 PM
Ebonee Davis
Ebonee Davis - avatar
0
Every individual's hair loss pattern and needs are unique. Hair replacement specialists for African American hair can tailor the procedure to your specific requirements, taking into account factors such as hair texture, density, and desired outcome. This personalized approach ensures that you receive the most effective and natural-looking results. See more detail here https://www.thehairtreatments.com/african-american-hair-restoration-in-chicago/
31st Oct 2023, 1:49 AM
Rtei Euwj
Rtei Euwj - avatar