I was tasked with re-writing a routine that managed the sendmail include file alias lists. The original routine was scary in what it did.
Stuff noticed:
33 loops to perform things ranging from reading/writing files, running a menu, to making sure an array was empty before using it.
Some of the logic was verify array was empty, load the file to an array, load the array to a variable, search the variable for an entry, add or delete something, load the variable back to an array, write to file. All of this with 6 loops
There is much more but then this post would be big! ;-)
What I was wondering is if there would be any worth publishing such messes for training purposes under the guise of say what not to do?
Just a random thought on a Sunday.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: A bad scripting section for teaching examples?
by ajt (Prior) on Jan 12, 2003 at 22:06 UTC | |
Re: A bad scripting section for teaching examples?
by BUU (Prior) on Jan 12, 2003 at 22:02 UTC | |
Re: A bad scripting section for teaching examples?
by Anonymous Monk on Jan 13, 2003 at 02:15 UTC | |
Re: A bad scripting section for teaching examples?
by Bismark (Scribe) on Jan 13, 2003 at 15:07 UTC | |
Re: A bad scripting section for teaching examples?
by data64 (Chaplain) on Jan 17, 2003 at 23:04 UTC | |
by Marza (Vicar) on Jan 18, 2003 at 04:42 UTC |
Back to
Perl Monks Discussion