edades_jovenes_mx = [
18, 22, 15, 27, 19, 24, 14, 21, 28, 16,
23, 19, 25, 13, 20, 26, 17, 29, 22, 18,
24, 15, 21, 27, 12, 23, 19, 25, 18, 28,
16, 22, 20, 26, 14, 24, 19, 29, 17, 21,
23, 15, 25, 18, 27, 20, 22, 16, 24, 28
]
suma = sum(edades_jovenes_mx)
cantidad = len(edades_jovenes_mx)
promedio = suma / cantidad
print("Suma:", suma)
print("Cantidad de datos:", cantidad)
print("Promedio mediante la fórmula:", promedio)
import statistics
promedio_mean = statistics.mean(edades_jovenes_mx)
print("Promedio mediante mean:", promedio_mean)
To embed this project on your website, copy the following code and paste it into your website's HTML: