At 07:38 2013-12-19, Nicholas Geti <ng...@optonline.net> wrote:
Yes. In 30 years of programming I only met two people who knew what
it was. I don't think it is taught in school any more. I would hate
to see it disappear which is why I brought up the subject. It has
come to my rescue in dozens of situations.
It might partly be a matter of vocabulary. "state transition
diagram" is another term.
It was taught in my computing diploma in the last semester. I
had previously used an extended version to implement a calculator.
Programming and debugging a finite state machine application is
almost trivial. The hard part is determining the states. But that
part is done with paper and pencil before one begins coding.
GASP! You mean planning in advance?
The books on the subject have relatively simple examples so the
student doesn't really see the value of it.
And complicated examples are a bear to follow.
Here is an easily understood sample from my experience:
[snipped example]
Here are mine.
1) My VFP app needed a string for how credit card transactions are
handled. The date had to be substituted in there somewhere once. I
used % as an escape character with "%d" meaning the date and "%%"
meaning a percent character. My FSM validated that the date escape
occurred exactly once and that all escape codes were correct and that
the string did not end mid-escape.
2) On my computing diploma, I implemented an FSM with additional
actions to implement a four-banger calculator. It took three
states. It was easy. My classmates who did not know the technique
were cursing the assignment.
Sincerely,
Gene Wirchenko
_______________________________________________
Post Messages to: ProFox@leafe.com
Subscription Maintenance: http://mail.leafe.com/mailman/listinfo/profox
OT-free version of this list: http://mail.leafe.com/mailman/listinfo/profoxtech
Searchable Archive: http://leafe.com/archives/search/profox
This message: http://leafe.com/archives/byMID/profox/
** All postings, unless explicitly stated otherwise, are the opinions of the
author, and do not constitute legal or medical advice. This statement is added
to the messages for those lawyers who are too stupid to see the obvious.