Remove an item from an IEnumerable collection

后端 未结 9 1790
死守一世寂寞
死守一世寂寞 2020-12-09 07:30

I have a popuplated IEnumerable collection.

I want to remove an item from it, how can I do this?

foreach(var u in users)
{
          


        
9条回答
  •  北海茫月
    2020-12-09 08:03

    You can't remove IEnumerable elements, but you can use the Enumerable.Skip Method

提交回复
热议问题