CSharp examples for LINQ:IEnumerable
Finding the first word that begins with 't' or 'T'
using System;// ww w . ja v a 2 s . co m using System.Collections.Generic; class Program { static void Main(string[] args) { List<string> words = new List<string> { "one", "two", "three", "four", "five" }; string firstTWord = words.Find(word => word.ToLower().StartsWith("t")); Console.WriteLine("\t{0}", firstTWord); } }