May be you have never heard of Edsger W. Dijkstra. But, if by any chance, you have anything to do with computer science, and you still don’t know about him, you will not be forgiven. If you are curious to read his stuffs, you can check E.W. Dijkstra Archive.

Anyway, I am not into computer science or programming, though I am trying to learn Python and other stuffs. While reading through Fluent Python authored by Luciano Ramalho, I stumbled upon a section which reads:

“The best defense of the Python convention of excluding the last item in ranges and slices was written by Edsger W. Dijkstra himself, in a short memo titled “Why numbering should start at zero”. The subject of the memo is mathematical notation, but it’s relevant to Python because Prof. Dijkstra explains with rigor and humor why the sequence 2, 3,…, 12 should always be expressed as 2 ≤ i < 13. All other reasonable conventions are refuted, as is the idea of letting each user choose a convention. The title refers to zerobased indexing, but the memo is really about why it is desirable that ‘ABCDE'[1:3] means ‘BC’ and not ‘BCD’ and why it makes perfect sense to spell 2, 3, …, 12 as range(2, 13). By the way, the memo is a hand-written note, but it’s beautiful and totally readable. Somebody should create a Dijkstra font. I’d buy it.”

Check this link for his essay in his handwriting.

This passage got me interested for three reasons. While learning Python, I was initially baffled with this zero based indexing practice. I mean I found this counter-intuitive. So this passage touched on this issue. Second reason it mentioned Dijkstra and I had no reason to ignore what Dijkstra had to say on any topic. Third reason this passage got me interested was about Dijkstra’s handwriting.

Subsequently, I submitted the link to Dijkstra’s essay to Reddit’s Programming community, though without any comment or description. One redditor remarked:

“Years ago, pre internet, these circulated as photocopies of handwritten originals. His handwriting was beautiful. Then someone showed you the one he wrote with his other hand for practice, which was just as perfect to look at.”

In reply to this comment, I pointed out the remark made by Luciano Ramalho ‘wants to buy the Dijkstra font’. Immediately after I made this comment, someone else pointed out that ‘Dijkstra font’ has probably been created and may be found at Luca Cardelli’s website.

Advertisements