Lambda 查询(C# 4.0)

class SimpleLambda
{
    static void Main()
    {

        // Data source.
        int[] scores = { 907182937582 };

        // The call to Count forces iteration of the source
        int highScoreCount = scores.Where(n => n > 80).Count();

        Console.WriteLine("{0} scores are greater than 80", highScoreCount);

        // Outputs: 4 scores are greater than 80            
    }
}
原文地址:https://www.cnblogs.com/zhangpengshou/p/2266351.html