21 lines
484 B
C#
21 lines
484 B
C#
using System;
|
|
|
|
class Student : Person
|
|
{
|
|
public string Faculty { get; }
|
|
public int Course { get; }
|
|
|
|
public Student(string lastName, DateTime birthDate, string faculty, int course)
|
|
: base(lastName, birthDate)
|
|
{
|
|
Faculty = faculty;
|
|
Course = course;
|
|
}
|
|
|
|
public override void Show()
|
|
{
|
|
Console.WriteLine("Студент: {0}, факультет: {1}, курс: {2}, возраст: {3}", LastName, Faculty, Course, Age());
|
|
}
|
|
}
|
|
|