Live data from Hacker News

The Manuscripts of Edsger W. Dijkstra

cs.utexas.edu

31–40 of 129 posts

Re: The Manuscripts of Edsger W. Dijkstra

#31
post #9

I'm amused at EWD498 - How do we tell truths that might hurt? https://www.cs.utexas.edu/~EWD/transcriptions/EWD04xx/EWD498... Besides a mathematical inclination, an exceptionally good mastery of one's native tongue is the most vital asset of a competent programmer. ... The use of anthropomorphic terminology when dealing with computing systems is a symptom of professional immaturity. ... Projects promoting programming…

Dijkstra was so based.

Re: The Manuscripts of Edsger W. Dijkstra

#32
post #16

Seeing book sections or chapters starting with zero, always confuses me. I know that this convention is probably inspired by the fact that the addresses of memory locations start with zero. But that case was due to that fact one of the combination of the voltages can be all zeros. So, it's actually the count of combinations, and I don't think it can be used for ordinal enumeration of worldly things such as book chapt…

If you’re at a corner and someone asks for directions, you say “three blocks that way”. That means three blocks starting from here. Then what do you call “here”? The name for where you start from in this scenario is usually not required because it’s obvious what you mean and everyone understands the first block means you have to first walk a block, not that where you start is the first block. So in that sense yes we…

Folks ... cardinal and ordinal numbers both have "just so" stories to support them. We're unlikely to eliminate either one of them today.

Re: The Manuscripts of Edsger W. Dijkstra

#33
post #16

Seeing book sections or chapters starting with zero, always confuses me. I know that this convention is probably inspired by the fact that the addresses of memory locations start with zero. But that case was due to that fact one of the combination of the voltages can be all zeros. So, it's actually the count of combinations, and I don't think it can be used for ordinal enumeration of worldly things such as book chapt…

The reason is that, for an array (or vector), you find the memory position for the i-th element with the base address + i*word_length. And the first element is in the base address - so has index 0.

It has memory offset 0, which we use as the array index for convenience so that there's no distinction between a memory offset-base and the corresponding array index-base. That's what happens when your arrays are barely different from pointers, as in C. If your arrays aren't just a stand-in for raw pointers, then there's little reason to require 0-based indexing. You can use more natural indexes based on your particular application, and many languages do allow arbitrary indices.

Re: The Manuscripts of Edsger W. Dijkstra

#35
post #19

Earlier quoted context omitted.

Zero is not an ordinal number. There can be a vector element indexed with zero, but it is not "zeroth" element. Book chapter numbers are ordinal numbers.

But what is there to gain with this distinction? Just the convenience of having an ordinal number to say? Rather than saying "chapter 0, chapter 1, chapter 2" one can say "the fourth chapter"? Or is it the fact that the chapter with number 4 has 3 chapters preceding it? On first glance I find this all rather meaningless pedantry.

If I use ordinal numbers to count, then counting tells me the number of objects. Sometimes I want to know the number of objects.

EDIT: Yeah, I don't know why book chapter labels shouldn't start with "0". It seems fine to me. They could use letters instead of numbers for all I care.

Re: The Manuscripts of Edsger W. Dijkstra

#36

I once had one of his quote on the back of my business card when I was doing a lot of software dev consultancy: "Computer Science is no more about computers than astronomy is about telescopes". I keep meaning to sit down with this site and make my way through it all. Might make more progress if I grab them into an eReader-friendly format and then peruse them more easily when travelling.

Astronomy is not named "Telescope Science" though. ;-)

Re: The Manuscripts of Edsger W. Dijkstra

#37

Completely silly fact: knowing 0 about the guy except that he gave his name to the famous algorithm, I had somehow assumed he was Indian. Weird to see a white Dutchman in the picture.

(Curious) How did Edsger Dijkstra sound like an indian name to you?

Re: The Manuscripts of Edsger W. Dijkstra

#38
post #16

Seeing book sections or chapters starting with zero, always confuses me. I know that this convention is probably inspired by the fact that the addresses of memory locations start with zero. But that case was due to that fact one of the combination of the voltages can be all zeros. So, it's actually the count of combinations, and I don't think it can be used for ordinal enumeration of worldly things such as book chapt…

If you’re at a corner and someone asks for directions, you say “three blocks that way”. That means three blocks starting from here. Then what do you call “here”? The name for where you start from in this scenario is usually not required because it’s obvious what you mean and everyone understands the first block means you have to first walk a block, not that where you start is the first block. So in that sense yes we…

"here" is definitely not a zeroth block. As soon you start walking, you are in the first block. However, if you are numbering the separations (cuts) between the blocks, you can number that "here" as zero.

Re: The Manuscripts of Edsger W. Dijkstra

#39
post #16

Seeing book sections or chapters starting with zero, always confuses me. I know that this convention is probably inspired by the fact that the addresses of memory locations start with zero. But that case was due to that fact one of the combination of the voltages can be all zeros. So, it's actually the count of combinations, and I don't think it can be used for ordinal enumeration of worldly things such as book chapt…

Building floor numbers in at least a few countries I’m aware of start from zero or “G” ( or the local language equivalent for “ground“) with 1 being the first story above the ground. I think you’re just biased to think that starting must “naturally” begin with 1. Zero is just a good a place to start and some people do start counting from zero.

The floor number case arises so because traditionally it is the count of "built" floors. So, ground is technically not a floor in that sense. Also, if the floor indicates a separation (cut) between the living spaces, ground floor can be numbered as zero, just like the start point of a measuring tape is numbered as zero.

Re: The Manuscripts of Edsger W. Dijkstra

#40
post #16

Seeing book sections or chapters starting with zero, always confuses me. I know that this convention is probably inspired by the fact that the addresses of memory locations start with zero. But that case was due to that fact one of the combination of the voltages can be all zeros. So, it's actually the count of combinations, and I don't think it can be used for ordinal enumeration of worldly things such as book chapt…

The first element in a collection at address 15 is at address 15. The offset of an element from the start is addr-start, so 15-15=0 for the first, 16-15=1 for the second, etc.

that's why we start from 0, not because of voltages, at least in compsci.

Post reply on HN