Download Which method performs better: .Any () vs .Count () > 0? book pdf free download link or read online here in PDF. Read online Which method performs better: .Any () vs .Count () > 0? book pdf free download link book now. All books are in clear copy here, and all files are secure so don't worry about it. This site is like a library, you could find million book here by using search box in the header.
.Count > 0 is best.Count() > 0 is fine, but ultimately just calls ICollection.Count.Any() is going to be slower, as it enumerates a single item; With non-ICollection (no .Count property).Any() is best, as it only enumerates a single item.Count() > 0 is bad as it causes complete enumeration.NET Core.Count > 0 is best, if available (ICollection)
Read : Which method performs better: .Any () vs .Count () > 0? pdf book online Select one of servers for direct link: |
---|