On Aug 7, 2010, at 3:53 PM, D'Arcy J.M. Cain wrote:
On Sat, 7 Aug 2010 15:37:23 +0200
Roald de Vries <downa...@gmail.com> wrote:
Would said beginner also be surprised that a newborn baby is zero
years
old or would it be more natural to call them a one year old? Zero
based counting is perfectly natural.
A new born baby is in his/her first year. It's year 1 of his/her
life.
For this reason, also "the year 0" doesn't exist. From the fact
that a
baby can be half a year old, you derive that arrays should have
floats
as indices?
No. You are giving me math and logic but the subject was common
sense. Common usage counts ages as years with the second year called
"one year old" so zero based counting is common. We don't tell Aunt
Martha that little Jimmy is in his third year. We say that he is two
years old and Aunt Martha, a non-programmer, understands exactly what
we mean. Using one-based counting (first year, second year, etc.)
would be the unnatural thing, would confuse Aunt Martha and make her
spoil her apple pie and no one wants that.
My point is that "0" in "Jimmy is 0" doesn't play the same role as in
"item 0 of a sequence".
--
http://mail.python.org/mailman/listinfo/python-list