Calculating age for a ‘leap-day’ birth date

Thursday 19 March 2015 @ 2:33 pm

I have a formula for calculating an age integer that has been on my site for a decade.  Yesterday I thought I had found a bug in it.  After I fixed the formula I did some more research and found that the original was correct in most situations. The question centers on cases, when a person is born on a ‘leap-day’ (February 29) and when exactly they turn a year older in non-leap years where there is no date of February 29.  In the UK and in Hong Kong their age would increment on March 1. In New Zealand or Taiwan their age would increment on February 28.  In many other jurisdictions, like most of the US, this isn’t specified anywhere, although the norm seems to be March 1.  My original formula will increment them to the next year on March 1.  But I have added an optional 5 lines of code to the formula for those who want the change to happen on 2/28.

(For examples of my most popular formulas, please visit the FORMULAS page on my website.)







Leave a Reply

Recrystallize Pro