}You can use it with any of the following function calls:
tot = sum2(array1, 5); // sum of a 5x4 array
tot = sum2(array2, 100); // sum of a 100x4 array
tot = sum2(array3, 2); // sum of a 5 x 2 array
---
The last example function call is incorrect, and he goes on in the next chapter explaining how the sum2d function would required to be changed to support more rows. There are 3-5 errors per chapter like this.
Solid 'B-'.
Rating:
Summary: Excellent Book So Far
Review: I am a Freshman in High School and I received this book a few weeks ago. To tell you the truth I haven't finished the book; I'm about half-way through but I just had to right a review on it.
The book shows a lot of good examples as it takes you through the different sections. Often times the book stops to tell about the concepts and throws in a diagram or example to make sure your still paying attention. The book often asks: How do you think this works? or what do you think function x does in this list of code? what's going on in this diagram/code? Sometimes these little questions help me to sit back and visualize the code instead of continuosly reading and trying to absorb a gob of information.
There are review questions and programming exercises at the end of each chapter. This definatly gives you the vibe of a classroom book; which it basically is. But, this book is very easily self-taught and there is no need for a teacher to teach you it, though a formal education is always the best way to go.
This book is definatly easy to understand. It is for the new users of C and experienced users alike. Don't be afraid to jump into this book if you don't know a scratch about C; after all, I did it!
It's been an excellent book so far and I would recommend it to others.
Rating:
Summary: a great book on c
Review: I am a Java programmer. To me, knowing the difference between Java and C is the most important thing. This book has very nice examples on important tricky points that a programmer should pay attention to; it saves me the trouble of making up my own examples and test them. I also like the fact that it has solutions to review questions, I find them to be very helpful. I have read several other good C books. This book is certainly among my most favorite ones.
Rating:
Summary: excellent book for learning c
Review: I bought both the third and fourth editions of this book and would buy them agaiin. I'm been very impressed with this book, it introduces C in such a way even someone with no programming experience can learn it without boring those who do have programming experience (at least too much).
The book covers basic to fairly advanced concepts and the reader have a good understanding of C if they take the time to use this book (do all the examples, etc).
An excellent book.
Rating:
Summary: Pure Ownage
Review: I don't usually read technical books cover to cover (especially code books) but this is one of the few. Prata is an amazing teacher. The world would be much better off with teachers like him. What I like best is he doesn't dumb down the content which makes the book flow. I also appreciate the fact this book isn't too technical which is helpful when you don't fully understand a topic at first. If you have entry level programming experience and want to advance by leaps and bounds THIS is the book. I thought C was an outdated language but after learning C ALL other languages just "click".
I have 20 or so programming books most of which turned out to just be reference books but this book can easily be read cover to cover and is a must have for ANY serious programmer.
Rating:
Summary: Easy to read, very informative
Review: Stephen Prata's "C Primer Plus, 4th Ed" (CPP4E) is an excellent book. I took a close look at the competition and even started reading O'Reilly's "Practical C Programming" before realizing CPP4E was the book for me. I had no C programming background, but had the knowledge of C-64 BASIC, Pascal, and other languages shared by many kids born in the 1970s. If you're looking for a well-conceived introduction to C, Prata's book is for you.
CPP4E impresses the reader on many levels. First, Prata's writing is exceptionally clear. He doesn't require you to dissect that one "key sentence" which encapsulates all the author has to say on a single topic. Prata defines all of his terms, uses them in examples, and reintroduces them when later new ideas require background presented earlier.
Second, CPP4E is a "teach yourself" manual. If you read the text, type in the examples, answer the review questions, and try at least some of the programming exercises, you will learn something. I typed many of the examples in the book by hand and also made use of the code supplied on the publisher's Web site. CPP4E should be used in classes as an introductory C book.
Third, it's evident a lot of thought and work went into publishing CPP4E. The index is thorough and applicable. The arrangement of topics makes sense. The diagrams are easy to decipher. The errata available on the publisher's Web site is comprehensive. I did find a few minor issues and submitted those to SAMS, which they acknowledged.
My only concern is the author's differentiation between "serious code" and "more relaxed programming." He says on p. 410 "in serious programming, you should use fgets() rather than gets(), but this book takes a more relaxed approach." Unfortunately, this relaxed approach is the reason why computers are constantly compromised. By now programmers should realize that users deploy their code in the most hostile of environments, and intruders will blow away anything that's not bullet proof. While Prata does show readers how to take more secure approaches, I'd like to see a security theme consistently applied throughout the fifth edition.
Overall, I strongly recommend CPP4E to anyone interested in an introduction to C. If you're looking for network programming, however, you won't find it here. Keep an eye on future reviews of mine for my picks on a socket programming guide. Keep in mind when reading this review that I'm a beginning C programmer. I'm not in a position to judge the author's style. However, I doubt many experienced programmers would read this entire book!
Rating:
Summary: A great start for new C programmers
Review: Stephen Prata's "C Primer Plus, 4th Ed" (CPP4E) is an excellent book. I took a close look at the competition and even started reading O'Reilly's "Practical C Programming" before realizing CPP4E was the book for me. I had no C programming background, but had the knowledge of C-64 BASIC, Pascal, and other languages shared by many kids born in the 1970s. If you're looking for a well-conceived introduction to C, Prata's book is for you.
CPP4E impresses the reader on many levels. First, Prata's writing is exceptionally clear. He doesn't require you to dissect that one "key sentence" which encapsulates all the author has to say on a single topic. Prata defines all of his terms, uses them in examples, and reintroduces them when later new ideas require background presented earlier.
Second, CPP4E is a "teach yourself" manual. If you read the text, type in the examples, answer the review questions, and try at least some of the programming exercises, you will learn something. I typed many of the examples in the book by hand and also made use of the code supplied on the publisher's Web site. CPP4E should be used in classes as an introductory C book.
Third, it's evident a lot of thought and work went into publishing CPP4E. The index is thorough and applicable. The arrangement of topics makes sense. The diagrams are easy to decipher. The errata available on the publisher's Web site is comprehensive. I did find a few minor issues and submitted those to SAMS, which they acknowledged.
My only concern is the author's differentiation between "serious code" and "more relaxed programming." He says on p. 410 "in serious programming, you should use fgets() rather than gets(), but this book takes a more relaxed approach." Unfortunately, this relaxed approach is the reason why computers are constantly compromised. By now programmers should realize that users deploy their code in the most hostile of environments, and intruders will blow away anything that's not bullet proof. While Prata does show readers how to take more secure approaches, I'd like to see a security theme consistently applied throughout the fifth edition.
Overall, I strongly recommend CPP4E to anyone interested in an introduction to C. If you're looking for network programming, however, you won't find it here. Keep an eye on future reviews of mine for my picks on a socket programming guide. Keep in mind when reading this review that I'm a beginning C programmer. I'm not in a position to judge the author's style. However, I doubt many experienced programmers would read this entire book!
Rating:
Summary: Easy to read, very informative
Review: This book is a great way to learn C. It doesn't baby the reader (I'd recommend having just a bit of programming background before reading it), it's easy to read, and it's very comprehensive. Once you're done with this book, you're just about ready to get into API programming. The book is organized very well, in that that Prata will gloss over a fact, giving you just enough knoweledge so as not to overwhelm you. Then, he'll return to the information later on, covering it in much deeper detail. This is a much better way to learn, since you have a varied skill set early on, instead of simply learning large amounts of information one topic at a time. It's also much easier to build on what you've learned since it's had the time to ferment in your mind. The book also has the best library reference out of any tutorial style book I've seen. The only problem is the repeated use of flawed functions, such as gets, scanf, strcpy and the like. He points out the flaws, but then completely ignores his own warnings! Of course, reading a more advanced book will cover in depth the flaws of these functions and discourage their use, but bad habits learned early on are hard to break. Overall, though, a great book! If I could, I'd give it a 4.5, but since I can't, I'll be generous and give it a 5. Also check out his C++ Primer Plus.
Rating:
Summary: Best C book!
Review: This book is simple enough for the beginning programmer and advanced enough to get you a very solid base in C. It is the best programming book I've read. I cant tell you how helpful it is. In my book all errors have been fixed and since I bought it a few months ago so there should'nt be any errors left anymore. The code for the book is easily attainable through Sams online website www.samspublishing.com too. Excellence!
Rating:
Summary: If you need to be introduced to C...
Review: This is the book that you want.
This book covers enough for you to use the language well, and it is quite detailed. In fact, this book is great teaching material for people who wanted to learn C. Not to mention the appendix covers many of the library function that came with a typical compiler, and the explanation throughout the book is clear, and easily understood.
Prata's C Primer Plus, and C++ Primer Plus, is essential for any programmer who wants to learn C/C++. Once you grasp the basics of the language, you would still want these books for reference.