On Monday, 6 February 2017 at 18:55:19 UTC, pineapple wrote:
One reason for zero-based indexes that isn't "it's what we're
all used to" is that if you used one-based indexes, you would
be able to represent one fewer index than zero-based, since one
of the representable values - zero - could no longer be used to
represent any index.
Also, it's what we're all used to, and it makes perfect sense
to a lot of us, and the only times in recent memory I've ever
made off-by-one errors were when I was trying to use Lua and
its one-based indexing.
In the scientific programming community, languages like Matlab,
Fortran, and R use one-based indexing for a very good reason.
Zero-based indexing is a computer science thing that makes no
sense to someone working with equations.