Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
07/17/01 07:11
Read: times


 
#13252 - RE: Program length?
Hi Brian,

1.
feel free to divide your project into many small files.
I prefer a size of one (= 70 lines) or two printed pages, but no more than 10.
The easy way, use the include statement.
The more professional way, build separate objects and link it together. This need more experience and more discipline but give more reliable code especially on bigger projects, since local variables can not be affected from other modules.

2.
I have also seen code with tons of conditional statements.
If it grows some time, such code was no longer maintainable :-(
At this point I have copied the code and resolved any condition.
And instead of many conditional testing only a single test exist, which include the appropriate file. Now the code can be read and understand again.
The disadvantage, if you must do some changes on it, every file must be changed.


Peter


List of 8 messages in thread
TopicAuthorDate
Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      
RE: Program length?            01/01/70 00:00      

Back to Subject List