2 ms·
I don't have any trouble with it, I just imagine the index as what it is: an offset, and the first element's location has the offset 0 from the start of the arr
by alpaca128 7y ago
I don't have any trouble with it, I just imagine the index as what it is: an offset, and the first element's location has the offset 0 from the start of the array.
For me it's far more confusing when I have to write code in a language with 1-based indexing, although I can see why e.g. Julia does it as it's more focused on mathematics and also in some cases the indexing is actually simpler when specifying a range.