As We May Code
The art (and craft) of computer programming in the 21st century

Alan Dix
Lancaster University
www.hcibook.com/alan/

keynote at PPIG08 – The 20th Annual Psychology of Programming Interest Group Conference. Lancaster University, UK. 10–12 September 2008.

download slides of talk (PDF, 877K)


Full reference:
A. Dix (2008). As We May Code - The art (and craft) of computer programming in the 21st century. keynote at PPIG08 – The 20th Annual Psychology of Programming Interest Group Conference. Lancaster University, UK. 10–12 September 2008.
http://www.hcibook.com/alan/papers/
PPIG2008-as-we-may-code/
More ...
Wikipedia page on Knuth's The Art of Computer Programming
slides of my talk (PDF, 877K)

 



Abstract

It is now 40 years since Knuth published the first volume of "The art of computer programming". This and the succeeding volumes (still being produced) form the definitive and monumental achievement in traditional algorithmics. However, the practice of programming has changed dramatically in recent years. Some changes are obvious: the use of technology in coding - from coding forms and punch cards to IDEs; the languages for coding - from Fortran and assembler to JavaScript and bytecode; and even the paradigms of coding - from procedures to objects. However, there are also more subtle, and possibly more fundamental changes that transform the way coders now think about their code and the very act of coding and hence affect centrally the understanding of the psychology of programming. In this talk I will try to draw out some of these changes writing from experience as a HCI 'expert', as a teacher and, perhaps most importantly, as a coder.

Keywords: TBD


As We May Code The art (and craft) of computer programming in the 21st century from Alan Dix

Comparisons - then and now

When I started coding you had:

  1. a problem to solve
  2. a relatively small set of simple primitives (data types, operators, constructs such as if-then-else)

Your job as a programmer was to find a solution to the problem using the primitives.

Now, instead of problem solving, programming feels like a British Library task: googling wikis, blogs, and semi-generated APIs to find a code snippet or piece of advice, more alchemy than chemistry.

Some changes seem for the good (such as the democratisation of coding through open-source communities), others less so. However, whether good, bad or simply different, coding now is not the same as it was 50 years ago when Knuth first wrote, nor for that matter 20, or even 10 years ago. And these difference are often ones that change the way we think about code and coding.

I'm trying to thrash out some of the main differences in the tables below. Of course, many things are more changes in emphasis and examples of 21st century programming practice can be found 50 years ago as can traditional programming be found now ... and of course some things never change!

Programmers
C20 C21
expertise specialists anyone  
mathematics strong weak  
team / community of practice organisational unit global community  
Programming
C20 C21
  problem solving recipe tinkering  
  mathematics classics  
  few well-understood primitives many partially-documented APIs  
  procedures events  
  inheritance mix-ins e.g. wordpress plugins, aspects
  single locus distributed  
  input/output, batch, pipeline
interactional / transactional see Wegner's work
  algorithmic
(make systems like algorithms)
systemic
(make algorithms like systems)
 
  pre-planned
top-down
emergent
bottom-up
 
client interaction at procurement and deployment throughout process  
  waterfall incremental/ evolutionary  
  speed of execution speed of development  
  reuse rare and difficult libraries, APIs, and code fragments  
documentation of libraries/APIs specification exploration  
authorship of documentation producer users wikis, blogs, etc.
Bugs and Debugging
C20 C21
  algorithm structural  
  single component feature interaction  
  unexpected input/event malicious attack  
  logical failure in new code misunderstanding of or error in infrastructure code  
  ALWAYS
trial and error vs. systematic
quick fix vs understand problem
some things don't change

Further Reading

  1. Donald E. Knuth (1968). The Art of Computer Programming.
    Volume 1: Fundamental Algorithms. First published 1968. Third Edition Addison-Wesley, 1997
    Volume 2: Seminumerical Algorithms. First published 1969. Third Edition Addison-Wesley, 1997
    Volume 3: Sorting and Searching. First published 1973. Third Edition Addison-Wesley, 1998
    Further volumes under preparation or planned.
  2. Donald E. Knuth (1974). Computer programming as an art. Commun. ACM 17(12) (Dec. 1974), 667-673. DOI=http://doi.acm.org/10.1145/361604.361612
    text also available at: http://www.paulgraham.com/knuth.html
  3. Ed Post (1983). Real Programmers Don't Use Pascal. letter to the editor of Datamation, 29(7), July 1983.
    text at: http://www.pbm.com/~lindahl/real.programmers.html
  4. Paul Graham (2003). The Hundred Year Language. keynote at PyCon 2003, April 2003. http://www.pbm.com/~lindahl/real.programmers.html

 


Alan Dix 25/8/2008