private static void ProcessStream(StreamReader reader) { string line = reader.ReadLine(); while (line != null) { string [] words = line.Split(' '); if (words.Length>0) ProcessLine(words,reader); line = reader.ReadLine(); } }