static void Main(string[] args) { var mark = 2; var language = Language.Foreign; var student = new StudentFactory(mark, language).CreateStudent(); student.Greet(); Console.ReadKey(); }