No me corrige el test

Buenas,

Estoy haciendo un test con 3 preguntas, pero el problema es que cuando pico en el botón CORREGIR, el test no hace nada y no sé donde puede estar el error. Os dejo el código a ver si alguien ve el problema. Gracias!

<html>
<head>
<title>Corrección de un test</title>
<script language="JavaScript">
function corregir(){
var p1
var p2
var p3
var aciertos = 0
var fallos = 0
var blancos = 0
var nota
var notaFinal
<!-- 1º pregunta-->
if (document.getElementById('p11').checked==true) {
p1 = -0.5;
aciertos++;
}else if (document.getElementById('p12').checked==true){
p1 = -0.5;
fallos++;
}else if (document.getElementById('p13').checked==true){
p1 = 1;
fallos++;
}else if (document.getElementById('p14').checked==true){
p1 = -0.5;
fallos++;
}else{
p1= -0.1;
blancos++;
}
<!-- 2º pregunta-->
if (document.getElementById('p21').checked==true) {
p2 = -0.5;
aciertos++;
}else if (document.getElementById('p22').checked==true){
p2 = 1;
fallos++;
}else if (document.getElementById('p23').checked==true){
p2 = -0.5;
fallos++;
}else if (document.getElementById('p24').checked==true){
p2 = -0.5;
fallos++;
}else{
p2= -0.1;
blancos++;
}
<!-- 3º pregunta-->
if (document.getElementById('p31').checked==true) {
p3 = -0.5;
aciertos++;
}else if (document.getElementById('p32').checked==true){
p3 = -0.5;
fallos++;
}else if (document.getElementById('p33').checked==true){
p3 = 1;
fallos++;
}else if (document.getElementById('p34').checked==true){
p3 = -0.5;
fallos++;
}else{
p3= -0.1;
blancos++;
}
nota = p1+p2+p3;
if(nota<0){
puntuación = 0;
}else{
puntuación = nota;
}
document.getElementById('aciertos').value = aciertos;
document.resultado.getElementById('fallos').value = fallos;
document.resultado.getElementById('blancos').value = blancos;
document.resultado.getElementById('puntuación').value = puntuación;
}
</script>
</head>
<body>
<FORM name="Preguntas">
<p>
<!-- Primera pregunta -->
1.- ¿De qué color es el cielo? </p>
<p>
<input type="radio" name="color" id="p11" value="A" /> Lila. </p> <p>
<input type="radio" name="color" id="p12" value="B" /> Verde. </p> <p>
<input type="radio" name="color" id="p13" value="C" /> Azul. </p> <p>
<input type="radio" name="color" id="p14" value="D" /> Rojo. </p>
<p></p>
<!-- Segunda pregunta -->
2.- ¿Cuanto son 2+2? </p>
<p>
<input type="radio" name="numero" id="p21" value="A" /> 6. </p> <p>
<input type="radio" name="numero" id="p22" value="B" /> 4. </p> <p>
<input type="radio" name="numero" id="p23" value="C" /> 7. </p> <p>
<input type="radio" name="numero" id="p24" value="D" /> 5. </p>
<p></p>
<!-- Tercera pregunta -->
3.- ¿El agua tiene sabor? </p>
<p>
<input type="radio" name="sabor" id="p31" value="A" /> No bebo agua. </p> <p>
<input type="radio" name="sabor" id="p32" value="B" /> Si, sabe a coca cola. </p> <p>
<input type="radio" name="sabor" id="p33" value="C" /> No tiene sabor. </p> <p>
<input type="radio" name="sabor" id="p34" value="D" /> Tiene sabor y color. </p>
<p></p>
</FORM>
<FORM name="botón">
<input type="button" name="botón" value=" CORREGIR " onClick="corregir()"/>
</FORM>
<br><br>
<b>RESULTADO DEL TEST</b> <P>
<form name="resultado" action="">
Has acertado <input type="text" size="3" name="aciertos" value=""/> preguntas <br>
Has fallado en <input type="text" size="3" name="fallos" value=""/> preguntas <br>
Has dejado de responder <input size="3" name="blancos" type="text" value=""/> preguntas <P>
PUNTUACIÓN: <input type="text" size="5" name="puntuación" value=""/> puntos
</form>
</body>
</html>

Añade tu respuesta

Haz clic para o