I want to compare two arrays with each other and see if there is a match, and if there is do something.
var answers = new Array(\"a\",\"b\",\"c\",\"d\", \"e\");
Try using this:
for(var i = 0; i < answers.length; i++) { for(var j = 0; j < correct.length; j++){ if (answers[i] === correct[j]){ console.log(answers[i]+ " is the correct answer") break; } } }