Live data from Hacker News

Ask HN: Zed Shaw's critique of K&R

news.ycombinator.com

11–20 of 22 posts

Re: Ask HN: Zed Shaw's critique of K&R

#15
I can see why Shaw made the article less accessible via search. Shaw has done the same with other essays he wrote around the same time. The basic analysis is sound. If you write programs like those in The C Programming Language those programs will lack mitigations for buffer overflows and null pointers.

A weakness of this essay is it jumbles pedagogical and engineering considerations together for dramatic effect. The defensive code Shaw does not find in K&R is only justified if crashing is both likely and worth the effort to prevent. YAGNI and "let it crash" are alternative engineering approaches.

The strength of Shaw's essay is that the grappling with the absence of defensive programming motivated Learn C the Hard Way to introduce Valgrind and Make right away. And the outrage probably adrenaline fueled Shaw's writing. All the controversy was consistent with Shaw's public image at the time, to boot. But in the end, the essay, like many of the period, lacks nuance. Their fading searchability is probably a sign of Shaw's recognition.

I think Learn C the Hard Way is better for Shaw having written the essay and I think his book is a pretty good introduction to C programming in part because it introduces Make and Valgrind and eschews IDE's. K&R is also good, but it's written with the assumption that the reader is ok learning from material written in a documentary style. That's less common today than four decades ago.

Re: Ask HN: Zed Shaw's critique of K&R

#16
post #12

Zed Python3-strings-are-too-difficult-for-me Shaw? I wouldn't bother with anything he's ever said or written.

What's the problem with his Python book? I bought "Learn Python the right way" for a close friend as I thought it was a good one to get started - is it not?

Re: Ask HN: Zed Shaw's critique of K&R

#17
post #12

Zed Python3-strings-are-too-difficult-for-me Shaw? I wouldn't bother with anything he's ever said or written.

What's the problem with his Python book? I bought "Learn Python the right way" for a close friend as I thought it was a good one to get started - is it not?

The book has multiple chapters on printing (!?) and the style of writing is incredibly condescending. It's one of the worst Python books I've come across. A sample of his idiocy - https://learnpythonthehardway.org/book/nopython3.html.

> When you start out programming the first thing you work with is strings, and python made them far too difficult to use for even an experienced programmer like me to use. I mean, if I struggle to use Python's strings then you don't have a chance.

To get away with this kind of attitude, one needs to be much smarter than he is.

Re: Ask HN: Zed Shaw's critique of K&R

#18
post #17

Earlier quoted context omitted.

What's the problem with his Python book? I bought "Learn Python the right way" for a close friend as I thought it was a good one to get started - is it not?

The book has multiple chapters on printing (!?) and the style of writing is incredibly condescending. It's one of the worst Python books I've come across. A sample of his idiocy - https://learnpythonthehardway.org/book/nopython3.html . > When you start out programming the first thing you work with is strings, and python made them far too difficult to use for even an experienced programmer like me to use. I mean, if I…

Given your ridiculous strawman of his Python 3 criticism, I won't be bothering with your review of his book.

Re: Ask HN: Zed Shaw's critique of K&R

#19
post #17

Earlier quoted context omitted.

The book has multiple chapters on printing (!?) and the style of writing is incredibly condescending. It's one of the worst Python books I've come across. A sample of his idiocy - https://learnpythonthehardway.org/book/nopython3.html . > When you start out programming the first thing you work with is strings, and python made them far too difficult to use for even an experienced programmer like me to use. I mean, if I…

Given your ridiculous strawman of his Python 3 criticism, I won't be bothering with your review of his book.

Not sure how it's a strawman, but let's address his statement directly.

Do you agree with him that Python 3 strings are difficult for experienced programmers? Apparently they are difficult for Zed Shaw as I quoted above. And also since they're difficult for him, does that mean that beginners "don't have a chance"? Demonstrably false and arrogant claims like this one, as well as many others in his Python and C books, make him lose all credibility.

Re: Ask HN: Zed Shaw's critique of K&R

#20
post #19

Earlier quoted context omitted.

Given your ridiculous strawman of his Python 3 criticism, I won't be bothering with your review of his book.

Not sure how it's a strawman, but let's address his statement directly. Do you agree with him that Python 3 strings are difficult for experienced programmers? Apparently they are difficult for Zed Shaw as I quoted above. And also since they're difficult for him, does that mean that beginners "don't have a chance"? Demonstrably false and arrogant claims like this one, as well as many others in his Python and C books,…

They are not difficult for Zed Shaw. You might not like his writing style, but disregarding context and interpreting statements literally that are quite obviously there for dramatic effect is in fact a strawman.

While I do find his writing entertaining, I wouldn't recommend it for beginners either. But not because he doesn't know how Python 3 strings work.

Python 3 was a disaster, and while his diatribe against it was questionable, the emotion behind it was not particularly misplaced.

Post reply on HN