Most Helpful Customer Reviews
|
|
8 of 8 people found the following review helpful:
3.0 out of 5 stars
Surprisingly interesting presentation, but needs better technical editing, and removal of non-ISO Standard usage & terminology., November 21, 2007
This book is well-written with material clearly presented. Its use of interesting mathematical examples, rather than the more typically forced and artificial ones in other texts, makes it an enjoyable book to read. The author's interest in the subject is evident, and infectious. The book is suitable for beginners, as the author presents material in a manner almost as if he's teaching us what he himself has recently learned and still remembers the problems beginners might experience.
There are, however, a number of problems, most minor but some more serious. In the minor category is the editing which could be somewhat improved. As early as page four a sentence contains an extra "is". On page 12 the author presents a formula to determine the range of minimum and maximum integer values and inadvertently and incorrectly uses bytes rather than bits in the formula. Fortunately, most of the technical editing errors are obvious with careful reading, and may even help readers feel they are really understanding the material.
Also in the minor category, and possibly reflective of the author's emphasis on using C++ for mathematical applications rather than on C++ itself, is his references to C++ items by names that differ from those commonly used by most C++ professionals. For example, he refers to the '<< insertion operator' as 'the << operation'. When introducing 'endl' he identifies it as the endl object, rather than, as is common, a 'stream manipulator'. He makes the stated choice not to use the more common C++ term `function' but chooses to refer to these program entities as procedures, so as not to have any confusion between the mathematical and computer uses of this term.
However, many mathematical terms are "overloaded". For example, 'modulus', is used with different meanings in arithmetic, complex numbers, set theory, elliptic functions, etc. Thus, the author's terminology decisions appear unnecessary for the intended audience, particularly, as these decisions make it a bit more difficult for readers to use other C++ references. The use of more common C++ terminology should provide greater value to the intended audience than the choices made by the author.
The author usually uses good coding practices, although there is the occasional slip. As one example, Program 3.5 finds the greatest common divisor of two integers using a 'for' loop. The loop ends when a variable exceeds the first number entered. This code is inefficient if the first number entered is greater than the second. If so, the values should be swapped before the loop, putting the smaller value first so the number of times through the loop is not unnecessarily large. This would improve speed without loss of generality.
Occasionally programming idioms that appear to be carry overs from a language other than C++ are used. They work, but are often not the most appropriate, efficient, or error reducing way to code in C++.
The more serious problems arise from the author statements about C++ constructs without regard for the ISO standard. He states that in the expression a%b, b can even be "zero!" (the explanation point is the author's). However, the standard notes that when the second operand of either the '/' or '%' operators is zero the behavior is undefined. Generally this results in runtime errors. In Exercise 2.3 readers are asked to determine the results of (-1)%3, (-5)%(-3), and 5%(-3). No reference is made to the ISO standard's statement that if both operands are not non-negative than the sign of the result is implementation-defined. There are similar problems with the author's answers regarding division by zero in problem 2.6. C++ beginners, the target audience, will not know which material presented here is inappropriate for standard implementations.
Although the book has 496 pages, and is 9+ inches high, it is relatively smaller than many other introductory C++ textbooks. This is due both to its comparatively lower page count, and its width which is about one inch less than some other popular introductory C++ texts such as Prata's or Deitel's. This has it pros and cons. Because of its smaller size and weight the book is much easier to hold and use. It also means the author has chosen to select those topics he feels most important and leave out many others. Of course a consequence of this is that the book contains less C++ content.
In spite of its deficiencies this is a book that's hard not to like. With a technical scrub by a C++ professional using the ISO standard, and the use of more common C++ terminology this book would be a standout. Its organization, writing, and explanations are exceptionally clear and the book is surprisingly, for a C++ text, entertaining. However, Chapman and Hall's pricing appears inappropriately high considering the book's relative size and paperback binding.
If the deficiencies mentioned above can be corrected, this would be an outstanding C++ text. A book I wouldn't hesitate to highly recommend as an excellent choice not only for mathematicians, but for others interested in quickly developing the skills needed to program quantitative problems in C++.
|
|
|
2 of 3 people found the following review helpful:
4.0 out of 5 stars
Perfect for learning, September 21, 2007
I bought this book a couple of weeks ago and have worked the exercises in the first four chapters so far. The exercises are perfectly chosen; the math is interesting and the programming is challenging, and there are thoughtful solutions to almost every exercise! It's obviously not appropriate for a future programmer, but for a mathematician who needs passing familiarity with programming it's perfect. Even if you don't want to use C++ in your work, a firm foundation in it gives you the freedom to branch out to Java, C#, or another language later on. I'd recommend it for anyone with a mathematical background who wants a fun introduction to C++.
|
|
|
|