using System; using System.Collections.Generic; using System.Collections; using System.Linq; using System.IO; public class Grupifail{ public static void Main(string[] argumendid){ var lapsed=from rida in File.ReadAllLines("nimepikkused.txt") select new{ eesnimi=rida.Substring(0, rida.IndexOf(" ")), pikkus=int.Parse(rida.Substring(rida.IndexOf(" "))) }; foreach(var laps in lapsed){ Console.WriteLine(laps.eesnimi+" pikkusega "+laps.pikkus); } } }