Live data from Hacker News

The Manuscripts of Edsger W. Dijkstra

cs.utexas.edu

111–120 of 129 posts

Re: The Manuscripts of Edsger W. Dijkstra

#111
post #110

Earlier quoted context omitted.

He ignores this basic argument: Positions in sequences like arrays are referred to using ordinal numbers (first, second, third, ...). There is no ordinal "zeroth". Ordinal numbers start at 1. This is contrary to cardinal ("how many?") numbers, which start at 0. And talking of "natural" numbers is besides the point. Therefore, referring to the seventh element in a sequence with the name "6" rather than "7" is confusin…

Using the same argument, why not place the origin point of cartesian coordinates at (1, 1, 1)?

Those use real numbers, which are different from ordinal (or cardinal) numbers. Ordinal numbers are positive whole numbers.

Re: The Manuscripts of Edsger W. Dijkstra

#112

Earlier quoted context omitted.

It is a strawman because nobody actually equates the ease of programming with the ease of making undetected mistakes.

Presumably no one thinks "I love using [dynamically-typed language] because I can make mistakes easier", but on the other hand, isn't it the case that large codebases are written with low initial friction but high future maintenance?

So you agree it is a strawman?

Re: The Manuscripts of Edsger W. Dijkstra

#113

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. ;-)

That's his point: "Computer Science" is a poor name for that area of study.

Re: The Manuscripts of Edsger W. Dijkstra

#114
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.

There are countries that don't? Do they just skip a number and go -2, -1, 1, 2, ...?

Re: The Manuscripts of Edsger W. Dijkstra

#115
post #95

The most important one in the context of 2025 is this one: On the foolishness of "natural language programming". https://www.cs.utexas.edu/~EWD/transcriptions/EWD06xx/EWD667...

Setting aside the the elephant in the room (modern coding LLMs are in some sense indeed compilers for natural language -- except they still "compile to" ordinary programming languages) it nonetheless seems to me that even conventional programming languages use too little, not too much, natural language. Example: - "&&" rather than "and", - "||" rather than "or", - "if (A) B" rather than "if A then B" This only makes…

For && and || I disagree: they are 'shortcircuiting' operators and as such they deserve a différent name than just 'and', 'or'. That said &| should have been named and,or which would have freed &| to use for the shortcircuit operators.

Re: The Manuscripts of Edsger W. Dijkstra

#116

Earlier quoted context omitted.

Presumably no one thinks "I love using [dynamically-typed language] because I can make mistakes easier", but on the other hand, isn't it the case that large codebases are written with low initial friction but high future maintenance?

So you agree it is a strawman?

Perhaps Dijkstra was going for the former, but is it bad to consider a stronger argument along the lines of what he said?

Re: The Manuscripts of Edsger W. Dijkstra

#117
post #95

The most important one in the context of 2025 is this one: On the foolishness of "natural language programming". https://www.cs.utexas.edu/~EWD/transcriptions/EWD06xx/EWD667...

Setting aside the the elephant in the room (modern coding LLMs are in some sense indeed compilers for natural language -- except they still "compile to" ordinary programming languages) it nonetheless seems to me that even conventional programming languages use too little, not too much, natural language. Example: - "&&" rather than "and", - "||" rather than "or", - "if (A) B" rather than "if A then B" This only makes…

Note that only about 1/3 of this critique (the last example, and with slightly different actual syntax in place of the preferred syntax) of "conventional programming languages" applies to the #1 language on the Tiobe index, which does, in fact, use and instead of && and or instead of || but uses ":" instead of "then" in if statements.

Re: The Manuscripts of Edsger W. Dijkstra

#118

Earlier quoted context omitted.

OK but I’m not sure I get your point then. Are you saying Edwin Aldrin was the first man on the moon because Neil Armstrong was the zeroth?

Not at all. Neil and buzz were first and second astronauts on the moon. If we ask who was on the moon before them then the answer is nobody. I think that’s agreeable. So then what am I talking about? It’s just counting. I’m going to explain this to whomever is interested, and anyone is free to tell me where I made a mistake, in which case I will thank them for the correction. When we talk about counting we say we are…

Clearly there is some contradiction if you claim the first chapter in a book is the “zeroth” chapter but the first man on the moon in the first man.

Re: The Manuscripts of Edsger W. Dijkstra

#119
post #86
post #82

Earlier quoted context omitted.

I’m not sure that is the focus of most serious dynamic language. For me, it’s the polymorphism and code re-use it enables that the popular static languages generally aren’t close to catching up to.

I’m curious, can you give an example that wouldn’t be solved by polymorphism in a modern statically typed OO language? I would generally expect that for most cases the introduction of an interface solves for this. Most examples I can think of would be things like “this method M expects type X” but I can throw in type Y that happens to implement the same properties/fields/methods/whatever that M will use. And this is…

That’s basically the main example I’d give. I think the static proponents with that opinion are a little myopic. Those sorts of relationships could generally be statically checked, it’s just that most languages don’t allow for it because it doesn’t fit in the OOP/inheritance paradigm. C++ concepts seem to already do this.

The “bug waiting to happen” attitude kind of sucks, too. It’s a good thing if your code can be used in ways you don’t originally expect. This sort of mindset is the same trap that inheritance proponents fall into. If you try to guess every way your code will ever be used, you will waste a ton of time making interfaces that are never used and inevitably miss interfaces people actually want to use.

Re: The Manuscripts of Edsger W. Dijkstra

#120
post #87

Earlier quoted context omitted.

When I'm counting letters it's more convenient to go "one, two, three." When I'm finding the offset between letters it's more convenient to go "zero, one, two." Neither of these methods is going to displace the other. Definitions are fine, and I agree that "A" is the first letter. But that's no use to people who need to think clearly about the offset between "A" and "C" right now. Should I tell them they're wrong, th…

Offset is an answer to the question "where does Nth memory location start from?". The answer is "after N-1 locations". It's the count of locations that need to be skipped by the reader, to reach the start of Nth memory location. Book chapters and page numbers are not offsets.

> Book chapter numbers are ordinal numbers

> Book chapters and page numbers are not offsets.

I don't know but I feel like you are making a point out of something arbitrary. When I listen to an audio book, everyone always says: "Chapter 1", not "the first chapter" so why is this important?

I think extreme attention to to arbitrary meaningless details is how we ended up with most rules in language that we are starting to collectively detest.

Post reply on HN