Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trial
Jimmy Names
10,371 Points(Javascript/IF statements/Task2:Challenge2/3) Code is fine but error 'Task 1 is not no longer passing' is stopping me??
var answer = prompt("What is the best programming language?");
if (answer.toUpperCase() === 'JAVASCRIPT') { alert('You are correct'); }
else { alert ('nah m8'); };
Yet keep getting: "Oops! It looks like Task 1 is no longer passing."
Task 1 is to write a variable called answer that prompts the user with the above question.. Ok'd before I wrote the IF statement.. suddenly it's not 'working'..?
Any help?
2 Answers
Unsubscribed User
8,841 PointsIf the challenge is "Making Decisions with Conditional Statements" -> "Introducting Conditional Statements"
Can you try like this one below:
var answer = prompt('What is the best programming language?');
if (answer === 'JavaScript')
{
alert("You are correct");
}
else
{
alert("JavaScript is the best language!");
}
Jimmy Names
10,371 Pointsahh man TY! finallly can move on..