Monday, December 17, 2007

And another great computer book


This entry is a follow-on to my earlier article titled "I'm going to read through Keeton this summer" where I talked about The New Turing Omnibus. Now, I want to talk a bit about another book I really like titled Practical Algorithms for Programmers by Andrew Binstock and John Rex

I've always been fascinated by algorithms - lists of instructions for carrying out a process or solving a problem. In one sense, a recipe is an algorithm for preparing a meal (or at least part of the meal). The best algorithms aren't just dry lists of instructions, though. Good algorithms explain why you are doing each step (much like how The Joy of Cooking handles food preparation). But sometimes, the reasons for each step of an algorithm are lost and someone has to go in and figure out why the algorithm is written as it is. Or, perhaps, the original explanation of the algorithm is poor and someone comes along and does a better explanation.

This book looks at some classic algorithms and explains them clearly and lists alternatives that may work better in some cases. It isn't a huge book and it doesn't cover a large number of subjects, like the famous Numerical Recipes series (with version for various programming languages from FORTRAN to C++). What Practical Algorithms for Programmers does is take the most useful algorithms and take the time to explain them well. It teaches you how to decide which of the algorithms to use for a given subject. It gives you background information on how the algorithms were developed. The subjects range from the basic (linked lists, stacks, queues, hashing, searching, sorting and trees) to the more advanced (date and time, arbitrary-precision arithmetic, data compression data integrity and validation). Each one is handled in a way to help you understand why you would want to use a certain algorithm and not to overwhelm you.

This is one of the books I bought because I was in a bookstore looking through all the books in a certain subject area. I didn't read other people's recommendations or do a search for any book with "algorithm" in the title. I was able to leaf through all the books and compare them. You can do this with many books on Amazon but not all. Of course, Amazon will have more books than can fit in a bookstore. But that can be part of the problem, too. Amazon often gives you too many choices. In a good bookstore, they have someone knowledgeable about a subject to pick the best books to stock. As I read through it and compared, Practical Algorithms for Programmers almost jumped out at me, grabbed me by the shoulders and said, "I can help you right now with this program and that program you are working on." That was enough for me.

No comments: