Ad

better indentation.
naming vars with their purpose.

Code
Diff
  • using System.Linq;
    
    public class Program
    {
      public static int FindSquaresInArray(int[] arr)
      {
        return arr.Sum(value => value * value);
      } 
    }
    • using System.Linq;
    • public class Program
    • {
    • public static int FindSquaresInArray(int[] arr){
    • return arr.Sum(x => x * x);
    • public static int FindSquaresInArray(int[] arr)
    • {
    • return arr.Sum(value => value * value);
    • }
    • }