Answers for "two lowest positive numbers given an array of minimum"

C#
0

two lowest positive numbers given an array of minimum

using System.Linq;

public static class Kata
{
  public static int sumTwoSmallestNumbers(int[] numbers)
  {
    return numbers.OrderBy(i => i).Take(2).Sum();
  }
}
Posted by: Guest on June-10-2021

Code answers related to "two lowest positive numbers given an array of minimum"

C# Answers by Framework

Browse Popular Code Answers by Language