Rules

img_2964

Taking my first steps in the world of programming, I’ve been intrigued to see that many of the overarching rules for ‘best practice’ and the more philosophical protocols for program design/code structure, are nearly the same as in screenwriting.

  1. Keep it simple.
  2. Show, don’t tell.
  3. Don’t repeat yourself.
  4. Only do one thing at a time.
  5. Write for your audience.

These aren’t rules in the traditional sense. They aren’t dictums passed down from on high that every programmer/screenwriter must adhere to. Occasionally you simply can’t keep it simple. You may well have to tell, rather than show. And sometimes, because it’s necessary (or because it’s something of an artistic flourish), you may have to repeat yourself.

Rather, these are popular rules, finely honed over the 120 years that people have written for the screen, and the 200+ years that programs have been written for machines.

It’s not just rules that translate between programming and cinema, though. There are quite a number of connections between the art of creating computer programs and the prevailing analytic approaches to film; but that’s for another time.

DOMs away

75% of the way through an Essentials course in JS, and I can’t wrap my head around the DOM. I get the concept, but the logistics of actually manipulating it are eluding me.

Yes, I realise there are simple syntax solutions to most problems. Variables, functions, arrays, etc, have well and truly sunken in, but the DOM is a wall in which I can’t seem to find a doorway.

Bah.

Entering the matrix

I’ve found myself frustrated in the last twelve months or so with a few mundane computer tasks that I have to undertake regularly, both for life admin and for work. Things like sorting out variable savings budgets, typing the same sentences over and over again in emails and other correspondence… I have also found myself wanting to play with websites in interesting ways, and am looking forward perhaps to looking at some of the intersections between cinema and code for research. All this — along with an institutional subscription to Lynda — has led me to undertake something of a crash course in programming. My initial efforts are the usual (Hello world, guess my number etc), but it’s enlightening to see how much work goes into the simplest of applications.

Stay tuned…