4 ms·
Is this book worth having as the K&R one or is it too outdated considering we are upon C2X?
by kensai 8y ago
Is this book worth having as the K&R one or is it too outdated considering we are upon C2X?
- simplicio 8y agoI read through it and found it interesting for the historical info and as a way to review the standard library. But if you're trying to get better at C, there are probably a lot of resources that are better uses of your time. It's pretty dated, the structure is a little hard to follow (he goes in alphabetical order of the header names, which given that a lot of the libraries reference each other, makes for somewhat confusing reading), and since he isn't targeting any particular architecture, the OS dependent stuff is pretty handwavy.
- pvitz 8y agoI think similar like Simplicio, but I would like to point you to Hanson's "C Interfaces and Implementations" which will show you how to organize your C code well and how to implement robustly ADTs. It is pretty educative and enjoyable to read.
- loeg 8y agoNo, but I don't think the K&R one is worthwhile either. It's far too outdated and teaches some bad practices. C99 in particular brought major improvements to the C language that you should be using. And C11 and C17/18 continued to refine the language in incremental ways.
- saagarjha 8y ago> I don't think the K&R one is worthwhile either. It's far too outdated and teaches some bad practices. It’s old, but I didn’t see anything horrible in the book. What bad practices does it teach?
- loeg 8y agohttps://news.ycombinator.com/item?id=9333520 https://news.ycombinator.com/item?id=9333520
- saagarjha 8y agoNot a fan of Learn C the Hard Way, but I will agree with you that K&R is a bit light on details of how/why to write safe C code. I stand by K&R being the best book for learning C that I’ve read, though it goes nicely with a good application security curriculum ;)