

CorrectAnswers = new Array();

CorrectAnswers[0]=2;
CorrectAnswers[1]=4;
CorrectAnswers[2]=4;
CorrectAnswers[3]=5;
CorrectAnswers[4]=4;
CorrectAnswers[5]=3;
CorrectAnswers[6]=1;
CorrectAnswers[7]=5;
CorrectAnswers[8]=2;
CorrectAnswers[9]=2;


macrightchar='O';
macwrongchar='X';
winrightchar='Bien';
winwrongchar='Mal';


var lidyy = 'win'
if (navigator.appVersion.indexOf('Mac') != -1) {lidyy = 'mac'}
if (lidyy == 'mac') {
	rightchar = unescape(macrightchar)
	wrongchar = unescape(macwrongchar)
}
else {
	rightchar = unescape(winrightchar)
	wrongchar = unescape(winwrongchar)
}

function CheckAnswer(){

	var CxaaN = 0;
	var TotalCorrect = 0;
	var pacKd = 0;
	var InsNect = 0;

	for (CxaaN=0; CxaaN<CorrectAnswers.length; CxaaN++){
		if (document.QuizForm.elements[CxaaN*2].selectedIndex == CorrectAnswers[CxaaN]){
			document.QuizForm.elements[(CxaaN*2)+1].value = rightchar;
			TotalCorrect++;
		}
		else{
			document.QuizForm.elements[(CxaaN*2)+1].value = wrongchar;
		}
	}
	InsNect = Math.floor((TotalCorrect*100)/CorrectAnswers.length);
	document.CheckForm.ScoreBox.value = InsNect + '%';
}



