Keeping it Small and Simple

2008.02.21

K&R – The C Programming Language

Filed under: c programming — Tags: , , — Lorenzo E. Danielsson @ 23:31

It’s been over 15 years since I last went through K&R’s The C Programming Language. The other day I decided to plow through it yet one more time.

This is still a book I think every programmer should read. It really is that good. The first time I read it I skipped through the text sections and mostly just looked at the code, only reading when there was something I didn’t understand. Now things are of course different. I have many years of C experience behind me and can focus on the text instead.

Kernighan and Ritchie tell you already from the very beginning (1.1 Getting Started): The only way to learn a new programming language is by writing programs in it. This is exactly what I always try to tell my students (and sadly many of them don’t seem to listen). I wonder if all the “Teach Yourself X in 24 hours” books actually tell you this basic truth? (How you will be an accomplished programmer in 24 hours is beyond me).

The authors also at an early stage make you write several versions of a program that prints a Fahrenheit-Celsius table. That way you get the idea from the beginning that there are different ways of solving a problem, and the part of your task a programmer is to figure out which solution is the most appropriate.

If you haven’t read The C Programming Language by Brian Kernighan and Dennis Ritchie before, then you should rush to your nearest bookstore and grab a copy immediately. If you have read it before, why not read through it again?

Advertisements

1 Comment »

  1. K&R, that is an interesting book indeed, it actually was the first “real” book I read on C myself (give or take a few other articles online about it). I loved the book I just had some problems solving the assingments given then I found this: http://users.powernet.co.uk/eton/kandr2/
    and many others like them, the point for me was not to cheat but to find other algorithms. I alway figured: “there is my way, your way and the right way” -_- There is no quick solution you just have to put in more time speaking in C to be able to think in it…

    Comment by Tlhokomelo — 2008.04.09 @ 21:42


RSS feed for comments on this post. TrackBack URI

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Create a free website or blog at WordPress.com.

%d bloggers like this: