code from a lightning talk I did on Erlang at XP Manchester