Thus, the LINQ (Language Integrated Queries) point is an easy way to work with enumerated collections when running memory. Contrast with SQL, which is the language for determining what a user retrieves from a dataset in a database.
- , SQL, LINQ- SQL , "" - . SQL ; LINQ - " ", foreach.
, :
foreach(Thing thing in things)
{
if(thing.SomeProperty() == "Some Value")
return true;
}
... LINQ:
return things.Any(t => t.SomeProperty() == "Some Value");
, , IL-. , .
LINQ; foreach, , , . , - - LINQ- foreach , , foreach?
"", foreach.