r/C_Programming • u/wizards_tower • Sep 09 '20
Discussion Bad habits from K&R?
I've seen some people claim that the K&R book can cause bad habits. I've been working through the book (second edition) and I'm on the last chapter. One thing I noticed is that for the sake of brevity in the code, they don't always error check. And many malloc calls don't get NULL checks.
What are some of the bad habits you guys have noticed in the book?
61
Upvotes
View all comments
Show parent comment
3
u/p0k3t0 Sep 10 '20
I assume you're just trolling, because this is about the worst piece of advice you could possibly give.