Monday, February 27, 2006

the search for the best programming language

Although I'm not a great programmer I've often had the thought in the back of my head that the search for the "best" programming language is an important philosophical issue. It's about world view. Do we prefer freedom or safety? Do we prefer bottom up or top down? Do we prefer free untramelled exploration or confinement?

Just as some people in the world are control freaks - they always have the best of intentions but I end up saying "no thanks" - some programming languages seem to be designed to constrain you rather than set you free.

It's becoming clearer by re-reading some of the introductory remarks in Structure and Interpretation of Computer Programs.

Brushing aside issues to do with syntax, clever algorithms and maths the authors say that writing a computer program is really about the intellectually difficult task of how to control a complex system. The programming language provides us with a means to express and explore ideas about this which would otherwise be too complex to manage.

They go onto outline the techniques used to achieve this, which are:
  • build abstractions that hide details where appropriate
  • build a user interface that enables us to "mix and match" well understood pieces
  • establishing new languages for describing a design (I hadn't understood that LISP can do this. Another thought is that Game Maker Language is such a language, with many game specific programming features)
They also talk about the nature of computing knowledge, that it is about the study of the structure of knowledge from a "how to" perspective. It is not just about describing the world, it is more to do with changing the world.

This is why I like computing. It ought to be a doing subject, about writing programs to do complex things that we couldn't do before. And it's why I don't like courses that focus on top down design and dry theory which is often divorced from real practice. It's about world view, who I am.

Sunday, February 26, 2006


Programming experts such as Paul Graham and Alan Kay are saying that modern languages like Ruby and Python are converging towards LISP (list processing), one of the first languages, invented 0ver 40 years ago!
If you look at these languages in order, Java, Perl, Python, you notice an interesting pattern. At least, you notice this pattern if you are a Lisp hacker. Each one is progressively more like Lisp.
- Revenge of the Nerds
You can download a free copy of Paul Graham's book, On LISP, here. I noticed a wonderful explanation of bottom up programming (despised by top downers) in his introduction.

In a recent talk, Alan Kay (who invented SmallTalk) identifies the two most important things about LISP as its metasystem and late binding. I don't fully understand this but am working on it. He said that LISP is the most important idea in computer science.

btw Alan Kay is part of the Squeak team which is a modern implementation of these ideas.

Paul Graham summarises the nine new ideas of LISP (when it appeared) in his Revenge of the Nerds essay. Ideas 1-5 are now widespread but the last 4 have by and large still not entered the mainstream:
The nine ideas are, in order of their adoption by the mainstream,
  1. Conditionals. A conditional is an if-then-else construct. We take these for granted now, but Fortran I didn't have them. It had only a conditional goto closely based on the underlying machine instruction.

  2. A function type. In Lisp, functions are a data type just like integers or strings. They have a literal representation, can be stored in variables, can be passed as arguments, and so on.

  3. Recursion. Lisp was the first programming language to support it.

  4. Dynamic typing. In Lisp, all variables are effectively pointers. Values are what have types, not variables, and assigning or binding variables means copying pointers, not what they point to.

  5. Garbage-collection.

  6. Programs composed of expressions. Lisp programs are trees of expressions, each of which returns a value. This is in contrast to Fortran and most succeeding languages, which distinguish between expressions and statements.

    It was natural to have this distinction in Fortran I because you could not nest statements. And so while you needed expressions for math to work, there was no point in making anything else return a value, because there could not be anything waiting for it.

    This limitation went away with the arrival of block-structured languages, but by then it was too late. The distinction between expressions and statements was entrenched. It spread from Fortran into Algol and then to both their descendants.

  7. A symbol type. Symbols are effectively pointers to strings stored in a hash table. So you can test equality by comparing a pointer, instead of comparing each character.

  8. A notation for code using trees of symbols and constants.

  9. The whole language there all the time. There is no real distinction between read-time, compile-time, and runtime. You can compile or run code while reading, read or run code while compiling, and read or compile code at runtime.

    Running code at read-time lets users reprogram Lisp's syntax; running code at compile-time is the basis of macros; compiling at runtime is the basis of Lisp's use as an extension language in programs like Emacs; and reading at runtime enables programs to communicate using s-expressions, an idea recently reinvented as XML.
MIT students take a course in LISP, The Structure and Interpretation of Computer Programs, which is available on line.

I guess I should have paid more attention to Brian Harvey. I have his books on logo (cut down LISP) but didn't go the next step, he has also co-authored a book on Scheme, a dialect of LISP.

chess, as a school subject

My school has agreed to let me teach chess as a subject. It will be a SACE Stage 1 Integrated Studies Unit delivered off line to students from Years 8-10.

I've put together a curriculum and received some valuable advice from Alan Goldsmith who runs the Knights and Bytes chess bookshop in Adelaide.

Here's my curriculum draft:

Skills Development (50%)
  • Demonstrated ability to identify tactical motifs - pins, forks, skewers, discoveries, double attacks, nets
  • Demonstrated ability to solve tactical problems at level 2 difficulty or higher from Blokh's "Combinational Motifs"
  • Demonstrated ability to master a list of endgame routines. Mate with: K + P versus K, 2 bishops, queen versus rook, (add some others) - ability to play both sides competently

Documentation and Evaluation (25%)

Record, analyse, annotate in detail and publish (on the internet) at least one significant competition game played by yourself

Research (25%)

Research one aspect of chess, such as
  • an opening
  • a famous game
  • a famous player
and present your findings to a group

Saturday, February 25, 2006

teen spirit

Danah Boyd has written a summary ("crib") of a recent presentation, Identity Production in a Networked Culture: Why Youth Heart MySpace

Some quick notes:

MySpace ("a place for friends") is second on the web for page views, more than Google

There is moral panic!

It began with an age limit of 18+, which has since dropped to 14 yo.

Youth prefer IM (synchronous) to email (old, adult stuff)

Dana explores these issues: identity production, hanging out, digital publics

Profiles (identity production)

Adult practices (sex, smoking, drinking) are appealing to youth, who want to be mature.

Important to look cool and receive peer validation

Comments on each others blogs are an important aspect of cultural currency

Friends are important

All of this is essential for youth (status games)

Hanging out

Teens chat on IM for hours

Digital publics

Physical presence is preferable but not always possible!

There are public, private and controlled spaces - for everyone

Increasingly, due to the moral panic teen space is becoming more and more controlled

Teens have increasingly less access to public space

IM provides a new way for teens to have private space, MySpace provides for public space

Youth do rub shoulder with adults, including creeps, online

Teens rarely chose to go private. They just wish the adults would go away. All of them - parents, teachers, creeps


Youth need private space

Adults restrict their private space in the "real world" so teens are searching for new spaces in the virtual world

Youth will be youth

Thursday, February 23, 2006

official optimistic bullshit

I wrote these words when teaching "in the north" (disadvantaged region of Adelaide) in the year 2000:

It is hard to find the right words for this but within Disadvantaged schools there is a growing lumpen sub culture. This is not a healthy rebellious working class culture. It's more of a lost generation, a despairing, almost feral subculture of Disadvantage without roots or traditions. Although this is a minority subculture it is growing in size and strength. Its presence in our classrooms is becoming more significant, challenging and intrusive.
- Optimism and Reality in Disadvantaged Schools

Read the whole thing.

I have spent most of my teaching career in Disadvantaged Schools.

Five years ago I made the switch to "senior school" partly because I didn't want to spend the rest of my life teaching year 8s and also because I felt I was becoming deskilled in computing, a rapidly changing field, which I love.

I've been lucky. Most of my classes have been great. But for the last 2-3 years I have worked part time to reduce stress and to keep up with computing knowledge. To tell you the truth I've been too busy learning new software packages to have much time left over for researching either educational, social or political theory although I still try to keep up in those areas as best I can.

However, some recent experiences make me realise that every word I wrote back in 2000 is still true. The ferals are still feral. And the bullshit hasn't stopped.

Our Government reaction: Put up the school leaving age. What self serving, passing the buck crap.

freedom and safety languages

The main programming languages I am currently using are GML (Game Maker Language) and JavaScript. I haven't looked at python for a while although I still want to, yada, yada, yada. Ruby I notice is the new kid on the block and growing very fast.

Anyway, I just came across this article which categorises programming languages as either freedom languages or safety languages. I don't see myself as expert enough to critically appraise the article but still it is interesting to read what an expert thinks. My gut reaction is that freedom languages are more suitable for schools.
What, pray tell, is a "freedom language"? Freedom languages are those languages that put the individual programmer at the center of their philosophical world.They work hard to remove any language constructs that reduce programmer freedom, and add the most powerful constructs available. Many are post-modern languages and most tend to be syntactically dense.

The other kind of language is the "safety language. Safety languages think first about the creation of contracts between modules, objects and functions. They focus on teams rather than individuals. They remove language features that are confusing or frequently misused so that there are fewer opportunities to make mistakes and so there can be clear separation of concerns and maximum verifiability. These languages are full of barriers and check-points and well-defined paths and they tend to be syntactically verbose.

Right now the "hottest" new freedom language is Ruby with Python second, but the most heavily used freedom language is Perl with Smalltalk second (my estimates, no science involved). The popular safety languages are C++, Java, C#, VB and Delphi. These collectively dominate modern programming. Other less popular safety languages include Haskell and Nice.

Tuesday, February 21, 2006

game maker skills challenges

I've updated my game maker skills challenges sheet, providing more detailed hints.

The techniques for making sprites, randomising, shooting, destroying, following, goal scoring, timing, platform jumping and pushing are covered.

I'm currently trialling it with my year 11 information technology class in combination with students blogging their solutions.

A more detailed summary, the full word doc and sample sprite strip sheets can be downloaded from the above URL.

Sunday, February 19, 2006

picasa file management

Google claims that picasa is intuitive but both myself and my students had problems with figuring out an easy way to manage files, ie. to manipulate an image in a variety of ways and then save the variations in one folder.

I read the Help and figured out how to do it and have blogged about the process here on my year 10 wordpress blog.

The fish collage is all done with picasa.

noughts and crosses

You can use GIMP to make a GIF animation. You make the pieces, like the grid, the nought, the cross and the winners line.

Then you add the crosses and noughts layer by layer and GIMP has the capability of turning it into an animation. I have a worksheet on this, send me an email if you want a copy: billkerr (at)

Saturday, February 18, 2006

animated gifs

I've written about how to create animated gifs using Game Maker at my Game Design 11 wordpress blog.

Unfortunately, blogger won't display animated gifs but wordpress will.

Correction: Blogger will display gif animations but not the default ones that are produced by the Game Maker image editor. I will have to research this further.

student blogs: preliminary observations

Here's are some preliminary observations about how my year 11 students IT blogs are progressing after 3 weeks.

The semester one IT course is about game design, making and issues about games (addiction, violence). The course is online here.

I've asked the students to solve a series of challenges and to blog about how they have solved the challenges. Some have had experience with game making and blogging before and some haven't, so the playing field is not level to start with.

I've started off by modelling the process and posting some instruction at I'll keep doing this if it seems to be useful but already I've noticed that students aren't much interested in my blog even though they are interested in each others blogs.

My marking scheme is 5 marks for each problem, broken down like this:
written solution out of 3 (A standard = 3, B=2, C=1, Requirement Not Met = 0)
help: out of 1 (who helped me, how did they help)
screeshot 1

As well as that I give bonus marks for off topic (1 a week), links, tips, categories, themes and blogroll.

By far the best thing so far has been that some students who are shy in class express themselves quite freely in their blogs. This is really striking for some students. It's also true that some students who are not shy also express themselves more fully through their blogs and since I'm prepared to put in some extra time and read their comments at home then I get to know their thoughts much better than I would otherwise. In short, blogging is fantastic for improved teacher - student connectivity.

However, there are a small number of students (boys of course) who seem to hate writing and it just may not work for them. You can't win them all.

Those students who have blogged before (I had some of them last year) are reading each others blogs and writing comments to each other. Most of students new to blogging haven't picked up on this yet, they are still finding their feet, but I know they will shortly and at that point their enthusiasm for the enterprise will grow.

What happens is a transition from one mindset (the teacher made me do it) to another mindset - I can own this myself and it's fun. This happens with the off topic posts and writing comments to each other, they begin to feel the power of their own free expression.

This creates problems for me of course. Bad language has cropped up earlier this year than last year. I want my students to express themselves freely but we're all trapped in a mind numbing, archaic, dumbed down to the max education system which frowns on such things. Oh well, we'll see what happens. Still thinking about the best way to handle it.

Today I've aggregated all the student RSS feeds at one spot which will help me keep track of updates.


One of my students told me yesterday that they (her and two friends) were having a "comment war" on one of their blogs. When I checked I found this amongst other comments:
ok then… *looks around for something funny to say* you know what, she was like “omg” and i was like “wtf?” and we loled because it reminded us of our favourite webcomic “omglolwtf?”
So, what am I meant to do? Here's a multiple choice of some of my thoughts:
  • laugh
  • chide her for inappropriate language
  • worry that the digital police will discover this and condemn me
  • don't worry because the digital police won't understand net language
  • rage about the digital generation gap
In the final analysis all I can say is, OMGLOLWTF

Wednesday, February 08, 2006

the teacher is sick today

For my year 10 computing class tomorrow I plan to introduce them to the 37 signals writeboard, which is really a simple but very clever wiki.

Here's my plan:

the teacher is sick today – but he will type in lesson instructions from home on this whiteboard – you are able to make comments here too – I wonder how it will turn out? – login and start reading and typing – hope it’s fun!

Anyone who reads this can visit the whiteboard to see how it went. I'll ask the students not to leave any names or personal information seeing how there might be visitors from "outside".

Tuesday, February 07, 2006

blogging course outlines

I'm blogging my course outlines for year 10 computing and year 11 Information Technology (stage 1 in South Australia) courses. For the time being I'm doing this so that students can work out their current tasks by reading my blogs.

I'm using wordpress for blogging and bubbleshare for photos.

I wanted to compare wordpress with blogger so that's one reason for using it. The other reason was that someone told me that wordpress wasn't blocked by the N2H2 filter and that was true for week one. But on Monday week 2 suddenly it was blocked. Fortunately, my school likes what I am doing and it has been unblocked locally following my request.

btw you can check out the N2H2 category database here. Teachers can use this to check whether sites are blocked from home, if they know which categories are blocked by default. You can get that information from the educonnect site.

I'm using bubbleshare rather than flickr also to check out bubbleshare - which doesn't require an account with a password. Also flickr has been taken over by yahoo and it's hard for some students to find a unique id with yahoo because it has become so huge.