a glob of nerdishness

February 8, 2008

Age algorithm

written by natevw @ 12:00 am

I think I’ve figured out an easy way to keep track of my age through the coming journey. All I need to do is subtract year_born from year_current.

You’re smacking your forehead because they’ve been teaching this in school since way before year_born. Well, the school method of figuring age out involves annoying trifles like “have I had a birthday this year?”. I haven’t practiced answering that question enough to be very good at it; growing up, I just knew how old I was because it was somehow important. Not anymore.

I think my simplification will serve me well in the coming years. Since I don’t usually mentally increment year_current until about February anyway, my method has a good chance of being right without needing any conditional branches.

3 Comments

  1. That’s the exact method I’ve been using for years, despite my October birthday. Works for me! :) The tough part is that since my year of birth has such a low digit in the ones column I always have to “regroup” before subtracting the current year and think like Mrs. Bush’s second graders “more on the top, no need to stop, more on the floor, go next door and get 10 more” Dad messed with my mind by telling me I could just double your age to get mine. And yeah, wow that works! How handy – so simple! Chances are I’ll forget to do that in the future so it’s another sure-fire solution. Thanks!! Mom

    Comment by Mom — February 9, 2008 @ 6:27 am

  2. Are you sure you don’t mean to complain about the zero digit in the current years’ tens column?

    Comment by natevw — February 9, 2008 @ 8:53 am

  3. I thought that was the only way to do it! The trick is to remember what year it is now:) Lois, if you keep doubling Nathan’s age to get yours, you will get old fast:)We won’t talk about the digits in my dob.

    Comment by g'ma — March 8, 2008 @ 5:36 am

RSS feed for comments on this post.

Sorry, the comment form is closed at this time.