Kernighan vs Deitel: Which C Programming Book Is Best for You?

  • Context:
  • Thread starter Thread starter doktorwho
  • Start date Start date
  • Tags Tags
    Books C programming
Click For Summary
SUMMARY

The discussion centers on the comparison between Kernighan's "The C Programming Language" and Deitel's "C: How to Program" for improving C programming skills. Participants agree that while both books are valuable, Deitel's extensive coverage and detailed explanations make it more suitable for beginners, especially for those preparing for exams. Kernighan's book is praised for its brevity and classic status but may lack the depth needed for newcomers. Ultimately, the choice depends on the reader's time commitment and learning style.

PREREQUISITES
  • Understanding of basic programming concepts
  • Familiarity with C programming syntax
  • Knowledge of pointers, structs, and unions in C
  • Awareness of C11 standards and undefined behavior
NEXT STEPS
  • Study the C11 standards and download the N1570 Committee Draft
  • Practice C programming problems focusing on pointers and data structures
  • Explore additional resources on C programming best practices
  • Review exercises from Deitel's "C: How to Program" for comprehensive understanding
USEFUL FOR

Students preparing for C programming exams, novice programmers seeking detailed explanations and examples, and educators looking for effective teaching resources in C programming.

doktorwho
Messages
181
Reaction score
6
https://www.amazon.com/dp/0131103628/?tag=pfamazon01-20

https://www.amazon.com/dp/0133976890/?tag=pfamazon01-20

These two books are recommended by my school's C programming course and i can't decide which to buy. I have a big test in about a month in which i will have 2 hours to write 3 programs and i need to improve my C programming skills. I primarily want a book that explains really well and has lots of examples and problems to do. These two get the greatest praise but since I am a little indicisive which do you recommend?
 
Last edited by a moderator:
Technology news on Phys.org
Both are good but Kernighan's is a classic of brevity at least it was in the first edition. This edition has 270+ pages vs Deitel's at 1000+ pages.

How much time do you have to read through them?

I'd go with brevity and do as many problems as you can. Also pay particular attention to pointers which are datatype specific, structs and unions. They are all very important to do effective C programming.
 
  • Like
Likes   Reactions: doktorwho
They are both good. Deitel's book is more expensive, but covers lots of details. If you plan on using C extensively in the future consider Deitel's. Also consider learning the C-11 standards by heart. Undefined behavior can make your life miserable if you don't understand it.

C11 - go here https://en.wikipedia.org/wiki/C11_(C_standard_revision)
Download N1570 Committee Draft

ISO-IEC 9899:2011 is the actual standard, but costs about $US300 last time I looked. N1570 is what most people refer to. I have one in the Desktop folder of Windows
 
  • Like
Likes   Reactions: berkeman, QuantumQuest and doktorwho
jedishrfu said:
Both are good but Kernighan's is a classic of brevity at least it was in the first edition. This edition has 270+ pages vs Deitel's at 1000+ pages.

How much time do you have to read through them?

I'd go with brevity and do as many problems as you can. Also pay particular attention to pointers which are datatype specific, structs and unions. They are all very important to do effective C programming.
The test which i described is in a month and deals with topics up to Pointers and the final is in two and a half months and deals with topics beyond pointers. Does that change your answer?
 
jedishrfu said:
Nope, as I'm not taking your test.
Haha, i meant is that enough time to read through the bigger one without confusing the hell out of me xD :D but thanks i decided to go for the Deitel's
 
  • Like
Likes   Reactions: jedishrfu
Its always best to pick your own book. My niece always told me that books speak and you'll know which onee is right.

I think you nade a good choice.
 
  • Like
Likes   Reactions: berkeman
doktorwho said:
https://www.amazon.com/dp/0131103628/?tag=pfamazon01-20

https://www.amazon.com/dp/0133976890/?tag=pfamazon01-20

These two books are recommended by my school's C programming course and i can't decide which to buy. I have a big test in about a month in which i will have 2 hours to write 3 programs and i need to improve my C programming skills. I primarily want a book that explains really well and has lots of examples and problems to do. These two get the greatest praise but since I am a little indicisive which do you recommend?

The two books are quite different in their philosophy. They are undoubtedly both very good. I have used Deitel's books (C, C++, Java, Internet and WWW) for many years extensively and they really worth their price and time to spend studying. They are full of details, exercises, problems and projects but need patience and devotion, in order to give you their full potential. I highly recommend them in general and particularly for your specific case. On the other hand, no one can doubt the great book by Kernighan, I've also used it but it is - as already has been mentioned, concise enough so it needs you to fill some details. It surely can be done either.
 
Last edited by a moderator:
  • Like
Likes   Reactions: doktorwho
For someone starting out, I would advise a book with more details and examples, so I echo the opinions in this thread favoring Deitel. IMO K & R (Kernighan and Ritchie) is a great reference for someone with some experience, but not as good if you're new at C.
 
  • Like
Likes   Reactions: QuantumQuest, doktorwho and jedishrfu

Similar threads

  • · Replies 7 ·
Replies
7
Views
1K
  • · Replies 17 ·
Replies
17
Views
2K
  • · Replies 16 ·
Replies
16
Views
2K
  • · Replies 1 ·
Replies
1
Views
2K
  • · Replies 1 ·
Replies
1
Views
3K
  • · Replies 3 ·
Replies
3
Views
2K
Replies
28
Views
5K
  • · Replies 34 ·
2
Replies
34
Views
5K
Replies
1
Views
1K
  • · Replies 29 ·
Replies
29
Views
8K