infundibulum

Introductory Python Docs?

May 5th, 2006

Something I’ve never understood about “beginner” tutorials in programming:

LiveWires 2005 : Python for the Inexperienced

This is a really nice tutorial, with interesting examples. But check out this bit:

Ranges

As you can see, Python’s loops are a bit different from BASIC’s and C’s. (And from those in most other languages, too. Lisp has something similar.) Instead of giving a range of values (as in BASIC), or a recipe for getting from each value to the next one (as in C), you give a list of values. Obviously this is more flexible; but what if you want to get the same effect as BASIC’s FOR loops?

Well, no, actually, a beginner never has heard of BASIC. Or (!) C. Or Lisp.

The Python documentation on Python.org is filled with stuff like this. Consider the first sentence in the “tutorial” “introduction” to Classes:

9. Classes

Python’s class mechanism adds classes to the language with a minimum of new syntax and semantics. It is a mixture of the class mechanisms found in C++ and Modula-3.

I mean, whatever, I guess there are plenty of people out there who are already programmers who will appreciate info like that.

About Modula-3.

In an introduction to Python.

But there an awful lot more people who are not, and who won’t.

Python seems to me to be the best choice for teaching programming, but outside of an O’Reilly book or something, I don’t think there’s much well-and-truly “for beginners” tutorial stuff around at all.

Not that I’m saying such stuff is easy to write — on the contrary, it’s mindbogglingly difficult. And I’ve tried.

Which is why I’m happy to discover an awesome wiki started by Frederik Lundh:

((An Unofficial) Python Tutorial Wiki)

Here’s the intro to Classes, not a Modula in sight:

Classes (introduction) ((An Unofficial) Python Tutorial Wiki)

Rad.

Leave a Reply