File size: 35,499 Bytes
3f69be3
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
<!DOCTYPE html>
<html lang="pt-BR">
<head>
  <meta charset="UTF-8" />
    <title>Prova de Língua Portuguesa e Matemática</title>
      <style>
          body { font-family: Arial, sans-serif; margin: 20px; }
              .questao { margin-bottom: 15px; }
                  .oculto { display: none; }
                      .resultado { margin-top: 20px; font-weight: bold; }
                        </style>
                        </head>
                        <body>

                          <div id="inicio">
                              <label>Nome do aluno: <input type="text" id="nomeAluno" /></label>
                                  <button onclick="iniciarProva()">Começar Prova</button>
                                    </div>

                                      <form id="formulario" class="oculto">
                                          <h2>Língua Portuguesa - 1º ao 5º ano</h2>

                                              <!-- Questões exemplo de Língua Portuguesa -->
                                                  <div class="questao">
                                                        <p>1. Qual é o plural de "flor"?</p>
                                                              <label><input type="radio" name="port1" value="certa" /> Flores</label><br />
                                                                    <label><input type="radio" name="port1" value="errada" /> Floras</label><br />
                                                                          <label><input type="radio" name="port1" value="nao" /> Não sei</label>
                                                                              </div>

                                                                                  <div class="questao">
                                                                                        <p>2. Qual palavra está correta?</p>
                                                                                              <label><input type="radio" name="port2" value="certa" /> Amigo</label><br />
                                                                                                    <label><input type="radio" name="port2" value="errada" /> Amigao</label><br />
                                                                                                          <label><input type="radio" name="port2" value="nao" /> Não sei</label>
                                                                                                              </div>

                                                                                                                  <div class="questao">
                                                                                                                        <p>3. Qual destas é uma frase?</p>
                                                                                                                              <label><input type="radio" name="port3" value="certa" /> O gato dorme.</label><br />
                                                                                                                                    <label><input type="radio" name="port3" value="errada" /> Gato feliz.</label><br />
                                                                                                                                          <label><input type="radio" name="port3" value="nao" /> Não sei</label>
                                                                                                                                              </div>

                                                                                                                                                  <h2>Matemática - 1º ao 5º ano</h2>

                                                                                                                                                      <!-- Questões exemplo de Matemática -->
                                                                                                                                                          <div class="questao">
                                                                                                                                                                <p>1. Quanto é 2 + 3?</p>
                                                                                                                                                                      <label><input type="radio" name="mat1" value="certa" /> 5</label><br />
                                                                                                                                                                            <label><input type="radio" name="mat1" value="errada" /> 6</label><br />
                                                                                                                                                                                  <label><input type="radio" name="mat1" value="nao" /> Não sei</label>
                                                                                                                                                                                      </div>

                                                                                                                                                                                          <div class="questao">
                                                                                                                                                                                                <p>2. Quanto é 10 - 4?</p>
                                                                                                                                                                                                      <label><input type="radio" name="mat2" value="certa" /> 6</label><br />
                                                                                                                                                                                                            <label><input type="radio" name="mat2" value="errada" /> 7</label><br />
                                                                                                                                                                                                                  <label><input type="radio" name="mat2" value="nao" /> Não sei</label>
                                                                                                                                                                                                                      </div>

                                                                                                                                                                                                                          <div class="questao">
                                                                                                                                                                                                                                <p>3. Quanto é 3 x 2?</p>
                                                                                                                                                                                                                                      <label><input type="radio" name="mat3" value="certa" /> 6</label><br />
                                                                                                                                                                                                                                            <label><input type="radio" name="mat3" value="errada" /> 5</label><br />
                                                                                                                                                                                                                                                  <label><input type="radio" name="mat3" value="nao" /> Não sei</label>
                                                                                                                                                                                                                                                      </div>

                                                                                                                                                                                                                                                          <button type="button" onclick="corrigir()">Ver Resultado</button>
                                                                                                                                                                                                                                                            </form>

                                                                                                                                                                                                                                                              <div id="resultado" class="resultado oculto"></div>

                                                                                                                                                                                                                                                                <script>
                                                                                                                                                                                                                                                                    function iniciarProva() {
                                                                                                                                                                                                                                                                          const nome = document.getElementById("nomeAluno").value.trim();
                                                                                                                                                                                                                                                                                if (!nome) {
                                                                                                                                                                                                                                                                                        alert("Por favor, digite o nome do aluno.");
                                                                                                                                                                                                                                                                                                return;
                                                                                                                                                                                                                                                                                                      }
                                                                                                                                                                                                                                                                                                            document.getElementById("inicio").classList.add("oculto");
                                                                                                                                                                                                                                                                                                                  document.getElementById("formulario").classList.remove("oculto");
                                                                                                                                                                                                                                                                                                                      }

                                                                                                                                                                                                                                                                                                                          function corrigir() {
                                                                                                                                                                                                                                                                                                                                // Pegando respostas
                                                                                                                                                                                                                                                                                                                                      const respostasPort = [
                                                                                                                                                                                                                                                                                                                                              document.querySelector('input[name="port1"]:checked')?.value,
                                                                                                                                                                                                                                                                                                                                                      document.querySelector('input[name="port2"]:checked')?.value,
                                                                                                                                                                                                                                                                                                                                                              document.querySelector('input[name="port3"]:checked')?.value
                                                                                                                                                                                                                                                                                                                                                                    ];
                                                                                                                                                                                                                                                                                                                                                                          const respostasMat = [
                                                                                                                                                                                                                                                                                                                                                                                  document.querySelector('input[name="mat1"]:checked')?.value,
                                                                                                                                                                                                                                                                                                                                                                                          document.querySelector('input[name="mat2"]:checked')?.value,
                                                                                                                                                                                                                                                                                                                                                                                                  document.querySelector('input[name="mat3"]:checked')?.value
                                                                                                                                                                                                                                                                                                                                                                                                        ];

                                                                                                                                                                                                                                                                                                                                                                                                              // Verificar se todas perguntas foram respondidas
                                                                                                                                                                                                                                                                                                                                                                                                                    if (respostasPort.includes(undefined) || respostasMat.includes(undefined)) {
                                                                                                                                                                                                                                                                                                                                                                                                                            alert("Por favor, responda todas as perguntas ou marque 'Não sei'.");
                                                                                                                                                                                                                                                                                                                                                                                                                                    return;
                                                                                                                                                                                                                                                                                                                                                                                                                                          }

                                                                                                                                                                                                                                                                                                                                                                                                                                                // Contar pontos
                                                                                                                                                                                                                                                                                                                                                                                                                                                      let pontosPort = 0;
                                                                                                                                                                                                                                                                                                                                                                                                                                                            for (const r of respostasPort) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                    if (r === "certa") pontosPort++;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          }

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                let pontosMat = 0;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      for (const r of respostasMat) {
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              if (r === "certa") pontosMat++;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    }

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          // Condição para passar (mais que 2 pontos em cada prova)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                const passouPort = pontosPort > 2;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      const passouMat = pontosMat > 2;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            // Mostrar resultado
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  const res = document.getElementById("resultado");
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        res.classList.remove("oculto");

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              res.innerHTML = `
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Nome: <strong>${document.getElementById("nomeAluno").value}</strong><br>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Nota Língua Portuguesa: ${pontosPort} / 3<br>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      Nota Matemática: ${pontosMat} / 3<br>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Resultado final: <span style="color: ${passouPort && passouMat ? 'green' : 'red'};">
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        ${passouPort && passouMat ? 'APROVADO' : 'REPROVADO'}
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                </span><br>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        Código: <strong>MIkael</strong>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              `;
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  }
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    </script>

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=Rwhehhehe/gi9h" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body>
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    </html>