ACCU Home page ACCU Conference Page
Search Contact us ACCU at Flickr ACCU at GitHib ACCU at Google+ ACCU at Facebook ACCU at Linked-in ACCU at Twitter Skip Navigation

Search in Book Reviews

The ACCU passes on review copies of computer books to its members for them to review. The result is a large, high quality collection of book reviews by programmers, for programmers. Currently there are 1918 reviews in the database and more every month.
Search is a simple string search in either book title or book author. The full text search is a search of the text of the review.
    View all alphabetically
Title:
C++ Primer Plus 4ed
Author:
Stephen Prata
ISBN:
0 672 32223 4
Publisher:
Sams
Pages:
1098pp
Price:
£36-50
Reviewer:
Francis Glassborow
Subject:
beginner's c++
Appeared in:
14-2
Last time a reviewed the latest edition of this author's book on C. In that case he had the advantage of a language that has remained very stable for a decade, not only from the perspective of the language design but also in the way in which it has been used. The effects of the changes that C99 introduced have still to impact on general coding style. C++ is totally different. It isn't so much the changes that have been made to the language itself but the vast changes that have been happening in the way that good programmers are using it. Those writing C++ have long cut loose from C and most would not advocate learning C or a C style as a precursor to learning C++. The author is, regrettably not among those. In his notes to instructors (page xvi) we find:

It doesn't assume prior knowledge of C, so it can be used without a C prerequisite. (some programming background is desirable however)

Now to me that puts it almost head to head withAccelerated C++but this book is well over three times the length. The very next bullet point is:

Topics are arranged so that the early chapters can be covered rapidly as review chapters for courses that do have a C prerequisite.

And that gives us the vital clue. This is an old fashioned book based on learning C++ based on C. OK so let me put aside my prejudices and try to assess this book on that basis.

It is hardly surprising that the poor student is going to have to master the intricacies of C-style strings almost from the start. However what did come as a rude shock was to find a section on universal character names in chapter three. I hardly think this is appropriate at this time. Indeed many programmers can get along quite happily without knowing about these. Unfortunately this example is typical of this book. The author appears to have no ability to filter information so that the student can keep their eye on the ball.

One thing that I always look at in books for novices and that is how the author addresses copying, in particular, copy assignment. It gives me no pleasure to report that this book is almost a decade behind the leading edge in that it is still providing the flawed exception UNsafe idiom of delete first then copy. So no credit there.

Another thing that I check is the handling of casts, and in particular the new style casts. In this case we are three quarters of the way through the book before the author deals with them. While I think that is far too late, I think that the problem is compounded by statements such as (page 772)

The purpose of this operator is to allow upcasts within a class hierarchy (such type casts being safe because of the is-a relationship) and to disallow other casts.

If you haven't guessed, he is writing about dynamic_cast. He actually does know the right answer because he earlier gives a better and more accurate description with examples (even if lacking depth).

Leaving aside the typos that litter the code, this book is ill conceived and poorly implemented. The author just throws things in because he knows about them without any coherent plan. There is no sense of structured learning here, and no sense of modern C++. He does not know what is new and what is not. He seems to have no understanding of the difference between the C and the C++ header names and calmly #include's such things as cstdlib after his using namespace std. No doubt that is the principle reason he advises readers that their compiler may need them to use the older stdlib.h header. He also places using namespace std in global scope in header files; completely unacceptable.

I could go on, but there is nothing in this book that is appropriate to the needs of someone learning C++ in the twenty-first century. It is time that Pearson Educational asked itself if it should be promoting bad books that will only reduce the revenues of other parts of the company that are publishing good books. The author of this book seems unable to discriminate between relevant and irrelevant information, sadly the publishers seem to be equally incapable of distinguishing books they should be publishing from those that they should not waste resources on.