1
Reply

What is the difference between IEnumerable, ICollection, and IList?

    IEnumerable: Allows iteration over a collection. Provides read-only access (no add/remove).
    ICollection: Extends IEnumerable to allow modification. Includes methods for adding, removing, and counting items.
    IList: Extends ICollection for indexed access. Allows accessing, inserting, and removing items by their index.