12. Quantify Data Flashcards
1
Q
What does the Any
method do?
A
It has two overloads.
- The first one is with no parameters and returns a bool indicating whether the sequence is empty or not.
- The second one takes a predicate function as a parameter and returns a bool indicating whether the sequence contains any item that returns true for this predicate.
2
Q
What does the Contains
method do?
A
Returns a bool indicating whether a specific item is contained in a given sequence.
3
Q
what does the All
method do?
A
Returns a bool indicating whether all items in the given sequence matches the predicate that’s passed to it.