Please explain my confused me like I’m 5 (0r 4 or 6).

  • Reil@beehaw.org
    link
    fedilink
    English
    arrow-up
    4
    ·
    7 months ago

    The language is rooted in the same logic as people. Your first year was between the ages of 0 and 1. The first year before you were born is between -1 and 0. There is no 0th year because 0 is a point in time and not a range in time.

    • jsomae@lemmy.ml
      link
      fedilink
      arrow-up
      1
      ·
      7 months ago

      Your explanation works equally well for any integer though. You could say the same of 1.

      I think you’re saying that it’s a fencepost issue. But even for personal ages this doesn’t check out: for a year after you are born, your age is “0.” A one-year-old baby is in the following year.

      • Reil@beehaw.org
        link
        fedilink
        English
        arrow-up
        1
        ·
        7 months ago

        I feel you’ve missed the point I was making and assumed I’ve made another. Age number and year number are different. You’re in your first year when your age is not yet 1. You’re in your second year when your age is between 1 and 2.

        Years follow numbers as in "this year was the first/second/third year of ", not “this year was the year turned X years old”

        • jsomae@lemmy.ml
          link
          fedilink
          arrow-up
          1
          ·
          edit-2
          7 months ago

          Oh I see. Sure, historically it makes sense that years have been ordinal numbers. But in the modern era with all our math and computational knowledge, it is not convenient anymore. It means off-by-one errors are easy to commit when comparing BC and AD years.

          This is why programming languages all index from 0 rather than 1 (knuth and lua be damned)