Skip to main content

programming outside my comfort zone

Sample Go language inside Notepad++ editor, using Java syntax highlighting
My experience with computer languages extends all the way back to APL (A Programming Language). I was exposed to it at the Fernbank Science Center in Atlanta in 1971. I got into APL for two reasons; the cool symbols across the top of the keyboard (a mechanical teletype) and the fact that I could play moon lander, one of the computer games written in APL that I later started to hack.

For a high school junior who was growing up through Star Trek, 2001, and the Apollo program, learning APL on an IBM 360 mainframe was a dream come true. Since then I have continuously been programming in some language, from assembly on up, on some platform, from microprocessors on up, until today, and I don't see myself changing until I can no longer see a monitor, sometime in the unknowable future.

For someone with such a very long period of software engineering in their lives, staying with any language or even a group of languages can result in creative stagnation. I have been programming in C since 1982 when it was Lifeboat C on an IBM PC XT under PC-DOS, C++ since 1986 when it was C with Classes under VAX VMS, and Java since 1995 when I downloaded it from Sun as a beta under Windows. I have certainly worked with other languages over the decades such as Ada, PL/I, Perl, Python, etc, but the stalwarts I always fall back to are the C trinity.

If you've not heard of Google's Go before now then you probably need to mosey on over and check out what Google has wrought. According to its Wikipedia entry, Go, or golang, is "an open source, compiled, garbage-collected, concurrent system programming language." It's important to realize that concurrency is not the same as parallelism. It's better. And that's why I'm very interested in this language. That, and the fact that two of Go's creators are Rob Pike and Ken Thompson, a pair of living computing legends. Or a pair of old dudes like me (except I didn't do anything nearly as useful as invent Unix, Plan 9, or the C programming language).

While I've yet to write anything substantial in Go (except to follow a number of tutorials), the impression I get of Go is a language that you would write if, after having put a few languages under your belt such as C, you could then go back and "do it better" after watching decades of adoption and use. An example of a "fix"? The language doesn't use an unadorned equals sign for assignment, but more like what Pascal and Niklaus Wirth find proper, the character sequence ':='. Niklaus Wirth was right to call the use of a bare equal sign for an assignment operator a "notorious example for a bad idea."

Another interesting feature is the elimination of elaborate class nomenclature. C++ and Java et. el.  has all sorts of coding rules for writing classes as well as how to then use them. Depending on the problem, these classes can become overly complex and unruly, especially in novice hands. In the Go example above you define a data structure which also serves as a class (you can do the same in C++, but not as cleanly), then define the method save() for this class that appears paradoxically outside the scope of structure for which it was written. The only indicator save() is a method of Page is its "receiver *p, a pointer to Page." This is something of a surprise to an old dog like me, but I think I will get used to it. I'll need to do a bit more class creation before I fully understand it, but it's not outrageous, especially if the rules for writing are simple and consistent.

The feeling I get using Go is of a stripped down no-nonsense kind of language trying to incorporate best practices as well as fix a few language mistakes (assignment notation is but one). It is fun, and it seems to have a reasonably low bar to understanding how it works and getting non-trivial work done. Whether it allows for "simple" programming remains to be seen. Code is by necessity at times complex and hard because the problems you are trying to solve are complex and hard.


Just finished a basic wiki server tutorial (the wiki is basic, not the tutorial), complete with interesting error handling, regular expression based validation, function literals and Go's version of closures. Not bad for a "new" (since 2007, or six years) language. It might not be a production wiki, but I do like the way key concepts were presented, such as error handling, validation, and patterns for code reuse.

I'd much rather build my mind doing something like this than wasting it along with money at some local Orlando tourist trap.


Popular posts from this blog

cat-in-a-box channels greta garbo

So I'm sitting at my computer, when I start to notice a racket in back. I ignore it for a while until I hear a load "thump!", as if something had been dropped on the floor, followed by a lot of loud rattling. I turn around and see Lucy in the box just having a grand old time, rolling around and rattling that box a good one. I grab the GX1 and snap a few shots before she notices me and the camera, then leaps out and back into her chair (which used to be my chair before she decided it was her chair).

Just like caring for Katie my black Lab taught me about dogs, caring for Lucy is teaching me about cats. She finds me fascinating, as I do her. And she expresses great affection and love toward me without coaxing. I try to return the affection and love, but she is a cat, and she takes a bat at me on occasion, although I think that's just her being playful. She always has her claws in when she does that.

She sits next to me during the evening in her chair while I sit in mi…

vm networking problem fixed

Over the weekend I upgraded to Windows 8.1, then discovered that networking for the virtual machines wouldn't work. Then I tried something incredibly simple and fixed the problem.

Checking the system I noticed that three VMware Windows services weren't running; VMnetDHCP, VMUSBArbService, and VMwareNatService. VMware Player allows you to install, remove, or fix an existing installation. I chose to try fixing the installation, and that fixed the problem. The services were re-installed/restarted, and the virtual machines had networking again.

Once network connectivity was established there was exactly one updated file for Ubuntu 13.10, a data file. This underscores how solid and finished the release was this time. Every other version of every other Linux installation I've ever dealt with has always been succeeded by boatloads of updates after the initial installation. But not this time.

Everything is working properly on my notebook. All's right with the world.

sony's pivotal mirrorless move

I'm a died-in-the-wool technologist, even when it comes to photography. I have always been fascinated with the technology that goes into manufacturing any camera, from the lenses (optics) through the mechanical construction, the electronics involved, and especially the chemistry of the film and the sophistication of the digital sensor. It's amazing that the camera can do all it's asked of it, regardless of manufacturer.

Of all the types of cameras that I've really taken an interest in, contemporary mirrorless (again, regardless of manufacturer) are the most interesting because of the challenging problems the scientists and engineers have had to solve in order to build a compact but highly functional camera. In particular I've followed the sensor advances over the years and watched image quality climb (especially with μ4:3rds) to exceed film and rival one another such that there's very little difference any more as you move from the smaller sensors such as 4:3r…