static void DoJobNewWay3()
{
var QuelquesPays = new[] {
new { Nom="France", Population=60000000, Superficie=550000},
new { Nom="Turquie", Population=70000000, Superficie=750000},
new { Nom="Chine", Population=1300000000, Superficie=9600000},
new { Nom="USA", Population=300000000, Superficie=9000000},
new { Nom="Maroc", Population=31000000, Superficie=450000},
new { Nom="Suisse", Population=7500000, Superficie=40000} };
var GrosPays = QuelquesPays.Where(p => p.Superficie > 1000000);
// Operations...
foreach (var p in GrosPays)
Console.WriteLine(p);
}
.method private hidebysig static bool
'<DoJobNewWay3>b__10'(
class '<>f__AnonymousType0`3'<string,int32,int32> p)
cil managed
.custom instance void [mscorlib]System.Runtime.CompilerServices.
CompilerGeneratedAttribute::.ctor() = ( 01 00 00 00 )
// Code size 18 (0x12)
.maxstack 2
.locals init ([0] bool CS$1$0000)
IL_0000: ldarg.0
IL_0001: callvirt instance !2
class '<>f__AnonymousType0`3'<string,int32,int32>::get_Superficie()
IL_0006: ldc.i4 0xf4240
IL_000b: cgt
IL_000d: stloc.0
IL_000e: br.s IL_0010
IL_0010: ldloc.0
IL_0011: ret
} // end of method Program::'<DoJobNewWay3>b__10'