Given a DateTime representing a person\'s birthday, how do I calculate their age in years?
DateTime
My suggestion
int age = (int) ((DateTime.Now - bday).TotalDays/365.242199);
That seems to have the year changing on the right date. (I spot tested up to age 107.)