Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
static void Main(string[] args)
{
Console.WriteLine(SumarCuadrados(new int[] { }));
Console.WriteLine(SumarCuadrados(new int[] { 1, 2, 3, 4, 5 }));
Console.ReadLine();
}
static int SumarCuadrados(int[] valores)
{
return valores.Sum(x => x * x);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment