this post was submitted on 11 Feb 2025
585 points (97.0% liked)
Programmer Humor
20039 readers
1745 users here now
Welcome to Programmer Humor!
This is a place where you can post jokes, memes, humor, etc. related to programming!
For sharing awful code theres also Programming Horror.
Rules
- Keep content in english
- No advertisements
- Posts must be related to programming or programmer topics
founded 2 years ago
MODERATORS
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
How is arrays starting at 1 still a controversial take. Arrays should start at 1 and offsets at 0.
Arrays are address offsets.
So what's 0 do then? I'm okay with wacky indexes (I've used something with negative indexes for a end-index shorthand) but 0 has to mean something that's actually useful. Using the index as the offset into the array seems to be the most useful way to index them.