var names = new List<string> { "Tom Cruise", "Tom Hanks", "Al Pacino", "Harrison Ford" };
var result = names.Where(name => name.StartsWith("Tom"));
foreach (var name in result)
{
Console.WriteLine(name);
}
var result = names.Where(name => name.StartsWith("Tom"));
foreach (var name in result)
{
Console.WriteLine(name);
}