Re:Edsger Dijkstra's note on starting array indices at 0 (pd...
by scott_s on Tuesday June 21, 2011 @07:34PM
(#2680858)
Yeah, I don't see what you're getting at. Where does "before" come in? We're assuming an arbitrary positive integer, not a sequence. And even if it was a sequence, I see no problems. Let's assume N == 5, then the mappings we get are:
This is a valid mapping from Z+ to our index space. Is your objection that 2 does not map to 2, 3 does not map to 3? That may be a useful property, but (i % N) + 1 is still a valid mapping without that property.
[ Parent
| on HN ]
There are no comments on this comment yet.