As many of you know, Edsger W. Dijkstra was an important and prolific mathematician and computer science. He was responsible for, among other things, the widely used shortest path algorithm.
One oddity of his work was that a substantial part of it was “published” as handwritten notes that he photocopied and distributed to colleagues. These notes were called EWDs because of his habit of labeling them with his initials and a sequential number.
EWD831 considers the question of which of the following notations should be preferred for referring to the sequence \(2, 3, \dots, 12\).
- \(2 \le i < 13\)
- \(1 < i \le 12\)
- \(2 \le i \le 12\)
- \(1 < i < 13\)
His conclusion is that 1. is the proper choice. That leads to another question: If we wish to use a sequence to index, say, an array or list, what should the first index be? His answer, of course, is zero. You can read EWD831 for his reasons for these conclusions. It’s short and will take only a couple of minutes. It’s a fascinating look at the thinking a great mind and his striving for simplicity.