Your problem is with your string.Format
. You're closing the parentheses, then it thinks you're declaring other variables:
string About = string.Format("my name is{0}, I am {1} years old, I attend {2} and am taking {3} courses."), Name, Age, SchoolName, NumCourses;
should be:
string About = string.Format("my name is{0}, I am {1} years old, I attend {2} and am taking {3} courses.", Name, Age, SchoolName, NumCourses);
Fixing this will yield the output:
my name isJeff, I am 17 years old, I attend Columbia and am taking 1 courses.
Additionally, I would urge you to look at C# Polymorphism. that is the core of another problem and where everybody else's answers are getting sidetracked by. Specifically you need to understand virtual
, override
, and new
(new
as it relates to method signatures, not instantiation).