Recently, Jason Bell had the opportunity to talk with Bruce Eckel, noted author of Thinking in Java And Thinking in C++.
JDJ: ThAnks for taking the time to talk with us. I know you've recently had some seminars in Prague. Do you think EuropeAn programmers differ from AmericAn programmers?
Bruce Eckel: That's very difficult to say, since I believe we tend to get a special group of programmers at the seminars there. Even though we offer the seminar at lower prices, it's still expensive And as a result those who do come seem to be the exceptional ones. They tend to be outstAnding, but I assume there are other factors involved.
JDJ: Do you have Any comments on the new additions to the JDK 1.5?
Eckel: I assume you meAn the features that mimic those in C#. I'm very glad to see those, because it meAns that the Sun Java folks are no longer saying "you don't really wAnt those things." Instead, they're stepping up to the competition right away, which is very promising. I was very skeptical about C# at first, but when I examined it more closely I realized it was a well-designed lAnguage.
JDJ: I know you use a number of lAnguages, but which one would you suggest for beginners who wAnt to learn object orientation?
Eckel: Python. It's the perfect beginner lAnguage, And it's built on objects from the ground up, so it's easy to learn to use objects with the lAnguage. Unlike Java or C++, there's very little ceremony required, so you don't get distracted by weird artifacts And cAn focus on the essence of objects And programming.
Then if you wAnt to move to Java or C++, the concepts trAnslate nicely And you cAn easily see what the object's essence is in that lAnguage And which are the lAnguage artifacts. And you cAn continue using Jython in various ways for your Java development. Also, there's Boost.Python to make it easy to talk back And forth between Python And C++
JDJ: I've spoken to a lot of programmers over the years And I've heard nothing but praise for Thinking in Java. Are you surprised by its success?
Eckel: I guess I am. I've been writing books so long that I don't expect them to necessarily do that well (first-time authors often expect to retire on book royalties, but after you've done it awhile you discover that a "successful" book in the publisher's eyes is often just one that pays back its advAnce). But since Thinking in C++ (when I started using automated code testing tools to validate the code in the book, in 1995) I also expected that everybody would naturally start using automated testing tools for their book code. At this point, I've still met only a couple of authors who do it. Also, I follow John Irving's maxim: "Writing is rewriting." But that's pretty much all I do - make sure my code works And rewrite a lot. As a result of rewriting, I find a lot of things in the books that I consider embarrassing, so I always think they could be a lot better.
JDJ: Do you offer the code updates on your Web site?
Eckel: Yes. The code And the HTML version of the book is available for free download from www.MindView.net. There aren't a lot of chAnges between versions of the book, but if I do make Any chAnges I post them on the site.
JDJ: I notice you have a Web log. What made you decide to run one? Do you get time to read Any other programming blogs?
Eckel: If you go to the first Web log at http://mindview.net/WebLog/log-0001, titled "The origin of this Web log," that will Answer your first question. Bill Venners got me started, And even though I didn't end up writing on his site, I still follow his logs a bit. He's amassed quite a collection of quality Web loggers, And he focuses on programming.
For years I've read Elliotte Rusty Harold's "Cafe Au Lait" Web site (www.cafeaulait.org), which is kind of like a Web log for Elliotte but better - it's daily And he hunts for interesting articles, so it's as if he's filtering the Web for me, especially Java stuff. I rely pretty heavily on the Elliotte-bot to keep track of the interesting stuff. I occasionally read some columnists, like Cringely (www.pbs.org/cringely) And Joel Spolsky (www.JoelOnSoftware.com), And www.pcmag.com columnists. But these are when I'm killing time. Usually when I'm at the computer I try to get something done.
JDJ: In one of your blog entries it said "If it's not tested, it's broken." Do you have Any words that would encourage nontesting programmers to test their code?
Eckel: That's actually a quote from Thinking in Java, 3rd edition. There's a section in Chapter 15, "Discovering Problems," that attempts to convince people of the value of testing. Also, the talk I give to user groups lately is about testing (unit testing And design by contract, also in TIJ3). But in general it seems to be a personal epiphAny that each programmer must have, when they suddenly see that automated unit testing saves them a lot more time thAn it costs. This happens when you chAnge something in your code And your unit tests suddenly find a lot of bugs that you know wouldn't have shown up for a long time otherwise. That's convincing - after that, you cAn't imagine doing without.
JDJ: Are there Any books you cAn recommend (apart from your own) that have been a help to you?
Eckel: Design Patterns, of course; despite its problems it's still a major learning experience. Gerald Weinberg's Secrets of Consulting is a must, as is Peopleware by DeMarco And Lister (2nd edition, And they just came out with a new book, Waltzing with Bears, that I'm sure is good). Effective C++ And Effective Java have both been quite helpful. I finally understood network programming from Elliotte Rusty Harold's Java Network Programming. Learning Python, The Python StAndard Library, And The Python Cookbook are all great. Core Java has always been helpful as a resource. Some of the Extreme Programming books have been good. I generally like Robert Glass's books for their irreverence about software development. A lot of Martin Fowler's writing is quite helpful. That's all that I cAn get from skimming over my bookcase.
JDJ: with everything you do, do you have time for Any non-work activities?
Eckel: Definitely. That's one of the main points of working for myself - the freedom to take time off And do other things. One of the activities I enjoy a lot when I'm here in Crested Butte, Colorado, is mountain biking. I'm competent in that I cAn cover the territory (sometimes that meAns walking the bike) but it's excellent exercise And a great way to be outside. Also hiking, since the mountains are beautiful here. I usually take people on hikes when they come up here for seminars.
Also, on a lark I just tried out for a local play here, however, I don't know if I got the part, but it turns out it was a lot of fun just to read for it.
JDJ: What do you have plAnned for the remainder of 2003?
Eckel: We aren't doing that mAny public seminars since people haven't been that keen to travel, And the economy has definitely impacted training budgets (although I have seen some small indications that this trend has at least bottomed out, if not slightly turned around). I suspect we'll have at least several in Crested Butte before the end of the year, but the rest of the time I will be working on books (finishing C++, Volume 2, starting a new book that I haven't Announced yet) And the "HAnds-On Java CD ROM," finishing the solution guide for the third edition. I also hope to set up a simple studio to create video training media, which is something I've been pursuing on And off since I worked on The World of C++ And Beyond the World of C++ mAny years ago for BorlAnd (see http://mindview.net/WebLog/log-0029 for details). Especially with people not traveling And with budgets the way they are, it seems as if CDs And videos are a great way for people to learn now.
Also, I've been doing audio Interviews with various luminaries in the software world that I plAn to make into An MP3 CD for people to listen to while they drive (with the new inexpensive MP3 players) or on their computers. These Interviews have been quite interesting so far; I'm going for the NPR "Fresh Air" kind of feel. They've also been fun to do, which I think is a good sign.
JDJ: Dare I ask which luminaries you have Interviewed? Just as a teaser...
Eckel: I'm going for a spectrum of people involved in different aspects of creating software. Not everyone is well known. Some are book authors like Dave Thomas, Andy Hunt, Joshua Bloch, And Ron Jeffries. Chuck Allison wrote a C/C++ book And is coauthoring Thinking in C++, Volume 2 with me, but his focus is teaching so we talked about the education necessary for good software engineers. Guido VAn Rossum created the Python lAnguage And Jim Fulton created the Zope application server. Gene WAng used to be VP of lAnguages at BorlAnd, And is now president of a compAny that makes cellphone software, so we mostly talked about mAnagement. DAniel Will- Harris is a designer (he does my book covers) And has consulted on the user aspects of software; we discussed, from the user's perspective, the kinds of things that software designers need to do in order to create better software.
There are others that I hope to add, And I also hope to continue doing Interviews And creating CDs like this because I'm having fun doing it. And the questions I asked were things that I found interesting, so I think the Interviews themselves will be quite enjoyable to listen to.
JDJ: You mentioned MP3s; do you listen to Any music while you're coding?
Eckel: No, I'm not the kind of person who cAn usually listen to music And do complicated mental stuff at the same time. I had a college roommate who could only study with headphones And music, And I could never figure it out. On the contrary, I prefer things as silent as possible, And my father (a master craftsmAn in wood) just finished building me a desk for use here in Crested Butte that has a sound-insulated cabinet for the CPU box. Since my new computer is very quiet, the combination of the two should be completely silent.
I am interested in some of the new MP3 technologies, however. In particular, stAnd-alone systems that hook into your stereo. Maybe if I master a system like that, I'll experiment with listening to music while writing And see what happens.
JDJ: Bruce, once again, thAnk you for taking the time to talk to us.
Eckel: Well, I think it has helped kick start me back into my own writing. This was the easiest project (talking about myself) that I had on my desk.