I am doing a tutorial series on .Net Academy and have run into a problem. They don't really have a useful help section so I was wondering if anyone here can help me. My issue is that I think I have done the code right, but I get this error:
Not all requirements have been met.
You must declare a DateTime property named DateOfBirth
Here is my code:
using System;
public class Person
{
public Person(string firstName, string lastName)
{
FirstName = firstName;
LastName = lastName;
}
public string FirstName { get; set; }
public string LastName { get; set; }
public int Age {get; set;}
public string GetFullName()
{
return FirstName + " " + LastName;
}
public int DateOfBirth()
{
return DateTime.Now.AddYears(-Age).Year;
}
}
public class Program
{
public static void Main()
{
}
}