Min

Input: IEnumerable<TSource>
Optional lambda expression:TSource => TResult

Min returns the smallest element from a sequence:


using System;
using System.Collections;
using System.Collections.Generic;
using System.Linq;

class Program
{
    static void Main()
    {
        int[] numbers = { 28, 32, 14 };
        int smallest = numbers.Min();  // 14;
        Console.WriteLine(smallest);

    }
}

The output:


14
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.