Synopsis: | Consider using Any() to determine whether an IEnumerable is empty |
Description: |
In many cases using Any() is more efficient than Count() . With Count() you risk that iterating over the entire collection has a significant impact.
|
Literature References: |
MS Design numerable.Count |