Example #1
0
        static void Main(string[] args)
        {
            Student student = new Student(new Person("Serhiy", "Pityk", new DateTime(2000, 3, 27)), Education.Bachelor, 312, 2);

            Console.WriteLine(student.ToShortString());
            Console.WriteLine(student[Education.Bachelor]);
            Console.WriteLine(student[Education.Master]);
            Console.WriteLine(student[Education.SecondEducation]);
            Exam[] exams = new Exam[2];
            exams[0] = new Exam("Math", 188, new DateTime(2017, 6, 13));
            exams[1] = new Exam("English", 164, new DateTime(2017, 6, 17));
            student.SetExam(exams);
            Console.WriteLine(student.ToString());
            Exam[] exams1 = new Exam[2];
            exams1[0] = new Exam("Ukrainian", 174, new DateTime(2017, 6, 20));
            exams1[1] = new Exam("History", 164, new DateTime(2017, 6, 24));
            student.AddExams(exams1);
            Console.WriteLine(student.ToString());
            CheckTime();
        }
Example #2
0
        static void Main(string[] args)
        {
            Student student = new Student(new Person("Ivan", "Ivanov", new DateTime(2001, 2, 1)), Education.Bachelor, 302, 13);

            Console.WriteLine(student.ToShortString());
            Console.WriteLine(student[Education.Bachelor]);
            Console.WriteLine(student[Education.Master]);
            Console.WriteLine(student[Education.SecondEducation]);
            Exam[] exams = new Exam[2];
            exams[0]      = new Exam("Calculus", 122, new DateTime(2018, 12, 23));
            exams[1]      = new Exam("Functional Analisys", 114, new DateTime(2018, 12, 19));
            student.Exams = exams;
            Console.WriteLine(student.ToString());
            Exam[] exams1 = new Exam[2];
            exams1[0] = new Exam("Fractal Geometry", 188, new DateTime(2018, 12, 20));
            exams1[1] = new Exam("Differential Equations", 111, new DateTime(2019, 1, 4));
            student.AddExams(exams1);
            Console.WriteLine(student.ToString());
            TimeCheck();
        }