Beispiel #1
0
        static AlapTxtBeolv[] BeAllomanyBeolvas()
        {
            StreamReader sr = new StreamReader("BeAllomany.txt");

            AlapTxtBeolv[] tomb = AlapTxtBeolv.Beolv(sr);
            sr.Close();
            return(tomb);
        }//Beolvassa a létrehozott állományt
Beispiel #2
0
        public static AlapTxtBeolv [] Beolv(StreamReader sr)
        {
            string [] sor;
            int       i     = 0;
            int       meret = int.Parse(sr.ReadLine());

            AlapTxtBeolv[] tomb = new AlapTxtBeolv[meret];
            while (!sr.EndOfStream)
            {
                sor     = sr.ReadLine().Split(' ');
                tomb[i] = new AlapTxtBeolv(int.Parse(sor[0]), int.Parse(sor[1]));
                i++;
            }
            return(tomb);
        }