"NickC" <[EMAIL PROTECTED]> wrote:
> The thing I love most about Python is the fact that callables can be
> slung around at run-time, just like any other object.

Yup.  A while ago, I was doing a lot of file parsing with state machines.  
Each state was a function.  The main loop of the state machine was just:

state = start
while state != end:
   state, output = state (input)

Each function was responsible for returning a (nextState, output) tuple.
-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to