- Shopping Bag ( 0 items )
An Algorithms Cookbook for VB Programmers
As a student of computer science, I had a fundamental principle drilled into my head time and time again -- languages come and go, but algorithms stand the test of time. A good algorithms reference doesn't need to focus on a particular language; however, those books tend to be crammed with computer-scientists' jargon, and provide less than an ideal starting point for the novice programmer. Rod Stevens' Ready-to-Run Visual Basic Algorithms, Second Edition is an attempt to bridge the gap, to help people who know the rudiments of programming in Visual Basic (VB) experiment with tried-and-tested algorithms and incorporate them into their own programs.
To make sense of this book, you must already be familiar with variables, conditional statements, loops, subroutines, and abstract data types. Even more advanced topics, such as class declarations and static variables, are introduced and used so quickly that a novice programmer will probably need an additional reference. In other words, Ready-to-Run Visual Basic Algorithms, is a logical "next step" for someone who has completed an introduction to VB programming, but you should make sure that you've understood at least one other book about VB before attempting to read this one. I applaud this approach, because it lets you concentrate on learning algorithms without getting bogged down by syntactic details.
Stephens describes all of the standard data structures that should be part of every programmer's toolkit: arrays, linked lists, stacks, queues, trees (including AVL and B-Trees), and hash tables. As for algorithms, he provides a competent description of the standard searching and sorting techniques (as you would expect from any algorithms book), a readable (and gentle) introduction to recursion, a reasonable discussion of decision trees and network algorithms, and a superficial treatment of hard (aka NP-complete) problems.
The book's first edition dealt with VB 3, which didn't support classes; this edition's final chapter is a grab-bag of miscellaneous information about object- oriented (OO) techniques that are possible with VB 4, but didn't seem to fit anywhere else in the revised text. This final chapter contains some interesting nuggets of programming wisdom, but it's too brief and jumps between topics too quickly to be of much use.
The book is accompanied by a CD with VB source code for the algorithms that it discusses, and example programs which let users interactively explore performance tradeoffs on their own computer system. The theoretician in me was pleased to find a short but adequate description of complexity analysis, including asymptotic bounds and "Big Oh" notation. I think that the author struck a good balance here between rigor and readability.
My major complaint about Ready-to-Run, is with its physical layout and typesetting. When terms are defined, they should be highlighted, or at least printed in bold type; the use of simple italics makes it hard to find the term in a page full of text. Likewise, equations are buried in the body of the text, which makes them hard to read; it would be helpful if they were centered, and denominators were printed underneath their numerators. The page layout algorithm often causes figures to turn up on the following page, in the midst of some unrelated text, necessitating annoying back-and-forth page-flipping. Also, the book would benefit from a few more diagrams and an additional metaphor or two. For example, when introducing stacks, Stephens merely states that:
"For historical reasons, adding an item to a stack is called pushing the item onto the stack, and removing an item from a stack is called popping the item off the stack."
Most programmers have eaten in a cafeteria at some point in their lives, and many will recall encountering a stack of plates in a spring-loaded dispenser there; the weight of a new plate added to the top of the stack pushes the entire stack down into the dispenser, while removing a plate from the top causes the spring to pop the stack back up. That's where the "historical" term comes from, and it's easier to remember the terms (and the last-in, first-out nature of stacks) once you've heard the story.
The cover of Ready-to-Run Visual Basic Algorithms, depicts someone dumping code out of a book directly into a computer. If that is your objective -- as a VB programmer, to quickly incorporate some standard algorithms into your code -- then this is a good place to turn. Also, if you already know VB and are looking for a quick introduction to algorithms, this book may be for you. Otherwise (if you're not using VB, or if you're seeking a deep understanding of the issues inherent in algorithm design), I'd recommend looking elsewhere. My personal favorite is Introduction to Algorithms, by Cormen, Leiserson, and Rivest (MIT Press, 1990). While programming languages have changed in the past decade, the design and implementation of standard algorithms hasn't.--Dr. Dobb's Electronic Review of Computer Books