Steven Giesel 12/15/2022

Array, List, Collection, Set, ReadOnlyList - what? A comprehensive and exhaustive list of collection-like types

Read Original

This article provides an exhaustive overview of collection-like types in .NET, including IEnumerable, IList, ICollection, Array, ISet, and immutable/readonly variants. It explains the distinction between interfaces and concrete implementations, offers guidance on when to use each type, and discusses concepts like lazy evaluation. Aimed at C# developers, it serves as a detailed reference for choosing the right collection type for APIs and internal code.

Array, List, Collection, Set, ReadOnlyList - what? A comprehensive and exhaustive list of collection-like types

Comments

No comments yet

Be the first to share your thoughts!

Browser Extension

Get instant access to AllDevBlogs from your browser

Top of the Week

No top articles yet