[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: programming standards ?



PureBytes Links

Trading Reference Links

> Could we at least agree upon the following:
> => Do NOT use Condition1, Condition2, Condition3 etc.
> => Do NOT use Value1, Value2  etc.

Amen, brother!!

I **HATE** reading code that's full of meaningless variable names 
like that.  Not only is it hard to read, it's more error-prone -- if 
you fat-finger your typing and enter Value21 instead of Value12, Easy 
Language will accept it very happily, and you'll have a nasty bug to 
track down.  If you type MyClsoe instead of MyClose, EL will flag it 
and you'll avoid a problem.

Comments are also CRITICAL for any code over about 10-20 lines, 
especially if you want anybody else to understand it (or if you want 
to understand it yourself next month!!).  Explain what's going on, 
why you did such-and-so, etc.  Maybe the code you write is totally 
clear to you at the moment you write it, but it's probably not 
totally clear to anybody else.

Gary