問題描述
I am the user a and I want their to be case .
我問用戶一個問題js 不區分大小寫比較,我希望他們的答案不區分大小寫。 They have a they use the or not.
無論是否使用大寫字母,他們都應該有正確的答案。 Any help with this would be .
任何幫助js 不區分大小寫比較,將不勝感激。
var name = prompt('Enter your name');
var correctAnswers = 0;
var questions = 15;

document.write('Okay '+name+' here is Question 1: What does html stand for?: HyperText Markup Language, High Track Making Language, High Tech Making Language');
var answer = prompt('Okay '+name+' here is Question 1: What does html stand for?: HyperText Markup Language, High Track Making Language, High Tech Making Language');
if (answer === 'HyperText Markup Language') {

console.log(correctAnswers = correctAnswers + 1);
console.log('That is correct!');
document.write('That is correct!');
} else {

console.log('Sorry that is wrong. The correct answer is HyperText Markup Language.');
document.write('Sorry that is wrong. The correct answer is HyperText Markup Language.');
}