On Jun 21, 12:22 am, Bruno Desthuilliers wrote:
> [EMAIL PROTECTED] a écrit :
> (snip)
>
> >>> I would like to be able to get a good hold of the concept
> >> state machines ?
>
> > Well both state machines and classes (objects). That may be a bit of a
> > tall order to take on all at once but the
> I've written code that looks a lot like that, and it's
> a perfectly acceptable pattern IMHO. I don't bother
> with the variables ON and OFF, though, as they add no
> clarity to simply using 'ON' and 'OFF' for the states.
>
> [...]
> The test portion of the code is actually longer than
> the cl
Thank you both for the insightful responses(I knew I came to the right
place)!
Steven -- The original inspiration was a "State Machine" your code re-
write was what I was trying to accomplish but quickly got in way over
my head. Thank you for expanding on that aspect of it. That will give
me some
Greetings,
I have been working on a little project today to help me better
understand classes in Python (I really like Python). I am a self
taught programmer and consider myself to fall in the "beginner"
category for sure. It was initially sparked by reading about "state
machines". This was my att