using System.Collections.Generic;
public static void Main()
var test = new List<IntStringPair>
new IntStringPair { id = 1, name = "Item 1" },
new IntStringPair { id = 2, name = "Item 2" },
new IntStringPair { id = 3, name = "Item 3" },
new IntStringPair { id = 4, name = "Item 4" },
new IntStringPair { id = 5, name = "Item 5" }
var foundItem = test.Select((item, index) => (item, index)).FirstOrDefault(x => x.item.id == 3);
if (foundItem.item != null)
test.RemoveAt(foundItem.index);
foreach (var item in test)
Console.WriteLine(item.name);
public class IntStringPair
public int id { get; set; }
public string name { get; set; }