Comment

Comment by serhei

Dijkstra's personal language design (GCL) actually used anything-based indexing -- you specify the lower bound explicitly when you declare the array, so even if indexing starting from some runtime value k (e.g. k=7, k=b.lower-bound for some existing array b, etc.) is most natural, you provide that as the lower bound. Then a(i) would be translated to e.g. a[i-k] in compilation.
parent serhei 9 days ago

No comments yet

Be the first to share your thoughts.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton