C is one of a handful of programming languages that every programmer should be familiar with. C’s influence and popularity continue to be unmatched. Even now, when programming languages are maturing and evolving, more software is written in C than in any other language [1,2]. Anyone who wishes to learn C has a plethora of resources to choose from--books, online tutorials, and classes taught in colleges, universities, and corporate environments. Among the many options available, though, a few stand out. This book is one of them.
This fourth edition covers C11 (ISO/IEC 9899:2011), the current language definition standard. Nearly everything a programmer needs to know in order to effectively develop new applications is covered, while some advanced topics and optional features are not. For example, threads and bounds checking are not mentioned, but variable length arrays, which C11 considers optional, are mentioned.
This is an outstanding book, suitable for both programming novices and for programmers familiar with other programming languages.
The book has 18 chapters and five appendices. Chapter 1, “Some Fundamentals,” contains a brief but excellent summary of programming, the role of high-level languages, operating systems, compilers, integrated development environments (IDEs), and language interpreters. Chapter 2,”Compiling and Running Your First Program,” tells the reader how to do just what the title says. Here, the author’s tone, which is maintained throughout the book, is first detected: in addition to explaining the core material, Kochan clearly and concisely gives the reader superb advice on the importance of paying attention to the small details--things such as selecting descriptive variable names and using white space and careful indentation--that help bring about programs that work correctly and are easier to maintain.
Chapters 3 through 15 present the bulk of the core material. Here, concepts are elaborated in short but complete programs that the reader can copy, run, and verify that the expected results are produced, since program outputs are also shown. These programs are accompanied by very thorough explanations of precisely what the programs are doing. The programs are simple but not trivial. The chapters end with several exercises. The illustrative programs and exercises are excellent. For example, two programs show how to generate prime numbers using different algorithms, while a third method is described in one of the exercises. Once again, Kochan’s experience comes through in very pithy comments and advice, presented in a straightforward manner without fanfare. He explains how the programs can be improved by adding, for example, input verification code. The cumulative effect is that the reader learns a programming language as well the craft of programming.
Kochan uses another technique: he describes a new feature of the language and follows it with an example program, and then asks the reader to try to understand what is going on before giving him or her a thorough explanation of the program logic. This is a great way to engage the reader in the learning process, as s/he feels the satisfaction of making a new mental connection and having it verified.
The final three chapters take a more global view. Chapter 16, “Miscellaneous and Advanced Features,” introduces unions, the comma operator, type quantifiers, command-line arguments, dynamic memory, and, surprisingly, the goto statement. Chapter 17, “Debugging Programs,” introduces the gdb utility. Chapter 18, “Object-Oriented Programming,” clearly presents the bare bones (Kochan calls it “a taste”) of this important topic; it shows how a simple example involving fractions could be coded in Objective-C, C#, and C++.
The book concludes with five appendices: “C Language Summary,” “The Standard C Library,” Compiling Programs with gcc,“ “Common Programming Mistakes,” and “Resources.”
In summary, I highly recommend this book for self-study and as a college-level textbook.
More reviews about this item: Amazon, Goodreads