From b2b8bb8f5c3ad1950e3b9a805181f56881045536 Mon Sep 17 00:00:00 2001 From: Agustin Lautaro Moneta <46840139@terciariourquiza.edu.ar> Date: Mon, 11 May 2026 14:14:33 -0300 Subject: [PATCH] Ejercicio 4 hecho --- ejercicios.js | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/ejercicios.js b/ejercicios.js index 098a6c3..6efe754 100644 --- a/ejercicios.js +++ b/ejercicios.js @@ -50,11 +50,18 @@ console.log(describir(persona)); */ const estudiantes = [ - { nombre: "Ana", nota: 88 }, - { nombre: "Luis", nota: 72 }, - { nombre: "Marta", nota: 95 }, - { nombre: "Carlos", nota: 60 } + { nombre: "Ana", nota: 88 }, + { nombre: "Luis", nota: 72 }, + { nombre: "Marta", nota: 95 }, + { nombre: "Carlos", nota: 60 } ]; +const notas = estudiantes.map(estudiante => estudiante.nota); +let SumaNotas = 0; +for (let i = 0; i < notas.length; i++) { + SumaNotas = SumaNotas + notas[i]; +} +const Promedio = SumaNotas / notas.length; +console.log(Promedio); // Resultado esperado: 78.75 /*