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 trialDavid Weigel
8,265 PointsCode works most of the time, others I get an odd Console error.
Hi there. For the most part my code (below) is working. Other times, I am seeing: "Uncaught TypeError: Cannot read property 'impl' of undefined(anonymous function) @ extensions::messaging:184".
I have seen this on some other workspaces, normally when I have an error. Any ideas?
var correctAnswers = 0;
function print(message) {
document.write(message);
}
var qAndA = [
["What is the capitol of Oregon?", "Salem"],
["What city in Oregon has the highest population?", "Portland"],
["What city was this quiz created in?", "Newberg"]
];
for(i=0; i<qAndA.length; i+=1){
if (prompt(qAndA[i][0])=== qAndA[i][1]){
correctAnswers += 1;
}
}
print("You got " + correctAnswers + " questions right!");
1 Answer
Stefan Dietz
2,360 PointsI think this error doesn't come from your code but from a browser extension.
Could you try to execute your code in a clean browser or incognito window?