static void Main(string[] args) { string n = Console.ReadLine(); // Entering a name of student. string i = Console.ReadLine(); // Entering a student ID. Student a = new Student(n, i); // Creating a new student who's name is written in string n, and i is student's ID. Student b = new Student("Assylanbek Nurmukhambet", "18BD110824"); // Creating another student who's name and ID is already written. a.Print(); // Calling a function that prints Student "a"'s information. a.Print(); // Calling Print function for Student "a" second time to check does the year of study increment. b.Print(); // Calling function to print Student "b"'s information. b.Print(); // Calling a function print for Student "b" second time. }
static void Main(string[] args) { Student Adilbek = new Student(); // sozdaem studenta Adilbek.Print(); // peredaem v method Print Console.ReadKey(); }
static void Main(string[] args) { Student s = new Student("Albina", "18BD110909"); s.Print(); Console.ReadKey(); }
static void Main(string[] args) { string name = Console.ReadLine(); string id = Console.ReadLine(); int year = int.Parse(Console.ReadLine()); Student st1 = new Student(name, id, ++year); st1.Print(); Console.ReadLine(); }
static void Function2() // ну здесь для ленивых, в этом моменте выводим данные, без ввода в плане имени и айди карты, тут лишь надо вывести год обучения { Student st2 = new Student("Yelaman", "18BD110462") { year = int.Parse(Console.ReadLine()) }; st2.Print(); st2.Inc(); }
static void Main(string[] args) { Student st = new Student("Margellan", "18BD110186", 1); // creating student st.Print(); // output that infos Student stu = new Student("Margellan", "18BD110186"); // there is without increment of year. stu.yearofs = st.yearofs + 1; // increment is here! stu.Print(); // calling with increment }
static void F2() // для вывода даннных, без ввода { Student st2 = new Student("Elvira", "18BD110190") { year = int.Parse(Console.ReadLine()) }; st2.Print(); st2.Incyear(); }
static void Main(string[] args) { Student st1 = new Student("aaa", "18BDxxxxxx"); //creating new Student within a class string s = Console.ReadLine(); int n = int.Parse(s); st1.Print(); //accessing name and id st1.Increment(n); //accessing increased year of study Console.ReadKey(); ////quiting the program by pressing any key (otherwise it closes immediately) }
static void Main(string[] args) { //Создаю переменную типа Student и передаю в неё имя и айди студента Student a = new Student(Console.ReadLine(), Console.ReadLine()) { year = 1 }; a.Print(); a.IncrementYear(); }
static void Main(string[] args) { //Создаю переменную а типа Студент Student a = new Student(Console.ReadLine(), Console.ReadLine()) { year = 1 }; a.Print(); a.Incr(); Console.ReadKey(); }
static void Main(string[] args) { Student Aruzhan = new Student("Aruzhan", 1, 66666); Student a = new Student(); a.Print(); a.nextyear(); Console.WriteLine(Student.count); }
static void Main(string[] args) { // Student st = new Student("Malika", "18BD"); //st.Print(); string[] inf = Console.ReadLine().Split(); //Считываем данные о студенте с консоли Student st = new Student(inf[0], inf[1]); //создаем экземпляр от Студента с этими данными st.Print(); //вызфваем функцию для выводда данных Console.ReadKey(); }
static void Main(string[] args) { string a = Console.ReadLine(); string b = Console.ReadLine(); int c = int.Parse(Console.ReadLine()); Student s = new Student(a, b, c); for (int i = 0; i < 4; i++) { s.Print(); ++c; } }
static void Main(string[] args) { Student student1 = new Student("Yerassyl", 10); student1.Print(); Console.WriteLine("Year: " + Student.year); Console.WriteLine(); Student student2 = new Student("Nurassyl", 22); student2.Print(); Console.WriteLine("Year: " + Student.year); }
static void Function1() // в данном этапе считываем все данные, использую методы, а также увеличиваем год и выводим данные { string s = Console.ReadLine(); string[] cheto = s.Split(); string name = cheto[0]; string id = cheto[1]; int year = int.Parse(cheto[2]); Student st1 = new Student(name, id) { year = year }; st1.Print(); st1.Inc(); }
static void F1() // считываем данные, используя методы, увеличиваем год и выводим данные через методы { string s = Console.ReadLine(); string[] str = s.Split(); string name = str[0]; string id = str[1]; int year = int.Parse(str[2]); Student st1 = new Student(name, id) { year = year }; st1.Print(); st1.Incyear(); }
static void Main(string[] args) { int y = 1; for (int i = 0; i < 4; i++) { // call class Student, give parametrs to class Student a = new Student("Amir", "18BD110123", y); Student b = new Student("Radmir", "18BD110321", y); a.Print(); b.Print(); // increasing year ++y; } }
static void Main(string[] args) { string l = Console.ReadLine(); string[] line = l.Split(); string s = line[0]; string ss = line[1]; int y = int.Parse(line[2]); Student a = new Student(s, ss) { year = y }; for (int i = 0; i < 4; i++) { a.Print(); } }
static void Main(string[] args) { Student s = new Student("Nurgali Eleonora", "18BD111398", 0); s.Print(); }
static void Main(string[] args) { Student Newstudent = new Student("Bekarys", 001); Newstudent.Print(); }