[Edu-sig] a Python title I'd like to see.... (idle fantasy)

kirby urner kirby.urner at gmail.com
Sat Dec 24 07:27:19 CET 2011


My idea of good Python lore would be an almost book length discussion,
at least, of the implementation of the "list" data structure.

Go through the C in great detail, using this as an excuse to teach C
in the context of it's supporting a higher language, looking ahead for
your readers, knowing some of them will be heading off into C#, Java
and PyPy implementations, at least.  Or have come from there.

Talk about what testing looks like, when working on Python, and where
can I get the tests, how might I set up shop as a developer (of Python
and other things).

One way is to read / compile / test the source code for Python itself.
 That's a curriculum I've proposed several times and I'm sure many
have thought of besides me:  cut your teeth learning Python and then
descend a level to a system language and begin studying the
implementation of Python in that language.

You'll start to appreciate Python in ways you never have, and you'll
start learning what nitty gritty memory allocation looks like, and
"declarative languages" (not the technical term -- compile-time
checked, type audited, the whole nine yards).

The thing is, you want your readers to be optionally following along,
doing their thing at the command line (fire up that gcc), meaning what
was "a book" is now this constellation of artifacts including
different versions of lessons depending on what kind of platform you
have.

Compiling Python on Windows is not only doable, it's highly
successful, but exactly how is it done?  Some readers would avidly
branch into that discussion, while others staying on a Mac (the
original Python was developed on a Lisa).

You've been studying the list type, as a data structure, have delved
into the history, of linked lists, bubble sorts, clever algorithms, a
kinds of class computer science.  Lots of names fly by, opportunities
to tell stories, fill us in.

Obviously it'd take a talented writer, far beyond my ken, to tie this
into LISP and the whole theory of S-expressions and like that, a heavy
dose of formality, somewhere in the middle of the book.

Make the list concept shine, but then come back to earth and have it
be one data structure among many.  Python celebrates diversity,
heterogeneity, cosmopolitan values.  The allure of crystalline purity
is thankfully muted in Pythonia.  We don't need it to be "seamless".

Because Python plays well with others, this is hardly just about
recruiting to Python.

We want to demystify computers more generally and find a
not-dumbed-down dissection of the list type, in terms of C, and even
lower level languages (how does C work), is just what a certain
segment of the public was craving.

A wild bestseller.  New York Times Review of Books is all agush.  "How
to think like a computer scientist on steroids...".

Dunno who could write it.  Might need to have interviews.  Maybe not a
book at all.  Direct to DVD?

Kirby


More information about the Edu-sig mailing list