static void Main() { Student[] students = new Student[] { new Student("Pesho",2134), new Student("Gosho",1234), new Student("Ivan",3456) }; Discipline[] disciplines = new Discipline[] { new Discipline("math",4,4), new Discipline("engl",5,3), new Discipline("bio",20,10) }; Teacher[] teachers = new Teacher[] { new Teacher("Mr Pesho",disciplines), new Teacher("Mr Gosho",disciplines) }; SchoolClass[] classes = new SchoolClass[] { new SchoolClass(1,teachers,students) }; School[] academy = new School[] { new School("Telerik Academy",classes) }; Console.WriteLine("{0}",academy); }
public SchoolClass(int schoolClassID,Teacher[] teachers, Student[] students) { this.SchoolClassID = schoolClassID; this.Teachers = new List<Teacher>(teachers); this.Students = new List<Student>(students); }