One of our projects here at CCS will be to mention books that contribute to Critical Code Studies (adding them to our LibraryThing account). Scott Rosenbergs Dreaming in Code: Two Dozen Programmers, Three Years, 4,732 Bugs, and One Quest for Transcendent Software offers some strong material history and reflection on development of a specific and open source piece of software, Mitch Kapors Chandlor. It gives a glimpse at the shear amount of human and machine activity and conflict surrounding the production of working code, all of which can inform CCS readings.
An excerpt offers one of the already typical moves of CCS, to perform a reading of a Hello, World program, especially in a comparative context. Nick Montfort, Michael Mateas, Beth Coleman, and I (among others) have already offered Hello, World readings.
A novice programmer’s first assignment in a new language, typically, is to write a routine known as “Hello World” — a bit of code that successfully conjures the computer’s voice and orders it to greet its master by typing those words. In Basic, the simple language of my Sumer game, it looks like this:
10 PRINT HELLO WORLD!
20 STOP“Hello World” programs are useless but cheerful exercises in ventriloquism; they encourage beginners and speak to the optimist in every programmer. If I can get it to talk to me, I can get it to do anything! The Association for Computing Machinery, which is the ABA or AMA of the computer profession, maintains a Web page that lists versions of “Hello World” in nearly two hundred different languages. It’s a Rosetta stone for program code.
“Hello World” looks more forbidding in Java, one of the workhorse programming languages in today’s business world:
class HelloWorld {
public static void main (String args[]){
System.out.println(Hello World!);
}
}Public static void: gazillions of chunks of program code written in Java include that cryptic sequence. The words carry specific technical meaning. But I’ve always heard them as a bit of machine poetry, evoking the desolate limbo where software projects that begin with high spirits too often end up.
Rosenberg passes quickly over the reading of Public Static Void a line that has even earned its place in the Urban Dictionary.
It is a favorite line to complain about. Complaints range from the problem the line reflects in Java.
Basically, the break down (cobbled together from various online texts)
public other objects can access this classes data or access the method from outside the class
static theres only one copy of the thing your declaring static in memory and you dont need to create an instance of the class
void it returns nothing
(this clearest explanation was posted here: in yet another discussion about just why this line of code is necessary.)
uj_ :The static main basically is a mistake. It just confuses newbies and they tend to write programs with static variables methods only.
>CeciNEstPasUnProgrammeur : Very good point. Doesnt really help much, though, because theyll still write illegible code. I prefer readable newbie code to un-OO newbie code though I like your suggestion, its just a drop in the ocean.
Teachers need to give more education on OO design and coding style.>uj_ : Yes static is a keyword you really shouldnt care much about at first so its a pity newbies have to deal with it when they write their very first line of Java.
Rosenberg however is doing a bit a Critical Code Studies by calling our attention to the evocations of those words strung together to evoke the void created in the public through the static of unfinished software. The words play off well the context of a public of newbies, the static or public static of disagreement over the need for the line itself, and the sense that its usefulness is void. Rosenberg folds this reading nicely into his larger discussion of software.
Although Rosenberg doesnt spelll out his reading, his gesture toward this specific line of code has a lot of CCS heft in it.