using System.Collections.Generic;
public static void Main()
List<float>notas = new List<float>();
int nNotas = LeerConsolaInt("Inserte cantidad de notas a ingresar: ");
for (int b = 0; b < nNotas; b++)
float dato = LeerConsolaFloat("Inserte nota " + (b+1));
for (int b = 0; b < notas.Count; b++)
sumatoria = sumatoria + notas[b];
float promedio = sumatoria / notas.Count;
Console.WriteLine("El promedio de notas es: " + promedio);
public static string LeerConsola(string msg)
return Console.ReadLine();
public static float LeerConsolaFloat(string msg)
return float.Parse(LeerConsola(msg));
public static int LeerConsolaInt(string msg)
return int.Parse(LeerConsola(msg));