gpollice

Archive for July, 2011|Monthly archive page

Book review: Seven Languages in Seven Weeks

In Book Reviews on July 23, 2011 at 12:00 pm

When I received my copy of Seven Languages in Seven Weeks: A Pragmatic Guide to Learning Programming Languages by Bruce Tate (Pragmatic Programmers, 2011), I wasn’t expecting to be impressed. First of all, I had read Tate’s From Java to Ruby and was not impressed by the book. I don’t usually read books aimed at managers, which may explain my disappointment. Also, how much real meat could be in a book that covered seven languages in less than 350 pages? Why most books that try to cover one language often push 1,000 pages—not that anyone in their right mind would actually read the full tome.

To my surprise, this book turned out to be a delight. This book doesn’t serve you the full language in a multi-course meal. Instead, it lays out the small tapas and lets you sample just enough to let you see if you like the taste. And, if you do, it gives you enough to keep you going until you order the full meal from another book, course, or combination of sources. What’s even more interesting is how Tate has selected tasty languages that each tantalize different parts of your intellectual pallet.

There are no common, “fast food” languages like C, Basic, or even Java here. Instead Tate offers avant-garde  languages that are gaining traction—or being rediscovered because they offer new paradigms or efficiences that we need for future applications and computing systems. His choices are Ruby, Io, Prolog, Scala, Erlang, Closure, and Haskell. Few people will know enough about all of these, and even if you do know something about all of them, the chances are that you’ll gain some additional insights.

Tate helps the reader approach each language by framing it with several questions that one should ask when learning any new language. These questions are:

  • What is the typing model?
  • What is the programming model?
  • How will you interact with it?
  • What are the decision constructs and core data structures?
  • What are the core features that make the language unique?

I recently used the chapter on Ruby to introduce the language to high school students. It worked wonderfully. When they were done, several of them decided to use Ruby for their project and did some very nice work in the span of about five days.

The book can be read comfortably in a weekend, but that’s like going to a wine tasting and chugging down everything in sight. Take your time with these languages. Use the seven weeks, or at least a few. Taste deeply and then decide which ones you want to learn more about. It will be a fun ride, and certainly worth your time.

Advertisements

Are the CS classics still relevant?

In Computer science on July 23, 2011 at 11:11 am

After years (decades) of waiting, with little teasers in the form of fascicles (a section of a book published separately), volume 4 (well, 4A) of Donald Knuth’s The Art of Computer Programming is finally available. This volume is about combinatorial algorithms. TAOCP is probably the definitive book on algorithms and the one that is most referenced in scholarly work. For many years computer scientists and programmers earned their stripes by using something from the first three volumes in programs they wrote. There was something about being able to say that the really cool routine you wrote to improve database access was derived from something you found in Knuth. Whenever a question about how efficient a program or routine was and whether there was a better way, you went to Knuth for the definitive answer.

So, to me, the release of the new volume is a really big thing—a really big nostalgic thing. I wonder how many of the current generation of software developers are excited, or even care about this release. There is no doubt that the number of people involved in computing has increased dramatically. Many of these people are programmers and not computer scientists or mathematicians. I don’t say this to belittle them. What they do is an honorable, important job. Decades ago, the state of computing was such that you really needed to be much more knowledgeable about math and the inner workings of computers than you do today if you wanted to write a program. Clearly, this is a good thing because the world’s appetite for software seems to be insatiable and we need to have as many people as possible preparing the dishes for the ravenous beast.

How many of this generation of software developers are able to, or even care to mine the depths of the works of people like Knuth to find the gems there that are hidden from mere mortals? I have the utmost respect for many of today’s technology heroes, but to paraphrase Sen. Lloyd Bentsen, “I knew Knuth, and these are not Knuth.”

Perhaps there is too much for any one person to know about computing today. That’s been true for decades, but Donald Knuth knows as much about the core concepts than anyone I can think of. I hope that we will see a renewal of interest in Knuth’s works with the publication of volume 4A of TAOCP and that it will inspire students as it did me and many of my friends.

What other people and classics are we missing today? I’d like to compile a list of those which inspired people and stand head and shoulders above others in their field.