Note that more comments doesn't equate to better code. Better code
equates to code that is efficient and easily readable. If you need a
long comment to explain some piece of code, consider breaking the code
up into more understandable pieces.

I use to think that you need a 2:1 comments:lines of code ratio. More
recently, however, I have understood the fallacy that are comment
ratio minimums.

I find it is also easier to write readable code and not have to
comment than to write really confusing code and then having to spend
time writing comments (which 90% of coders hate doing anyway).

My strategy is to write a purpose statement at the beginning of every
function saying what the function's purpose is. That is more than
enough. What's more important is producing examples of how to use
features of the software (web2py book).

Just my 2 cents.

On Mar 5, 10:50 am, mdipierro <mdipie...@cs.depaul.edu> wrote:
> I do not know. It is strange. Perhaps we should measure that
> ourselves.
>
> On Mar 5, 12:35 pm, villas <villa...@gmail.com> wrote:
>
> > Hmm,  Web2py has 85,000 lines of HTML.
> > I wonder how that is measured?  Is that credible?
>
> > On Mar 5, 6:08 pm, mdipierro <mdipie...@cs.depaul.edu> wrote:
>
> > > I just came across these:
>
> > >https://www.ohloh.net/p/web2py/analyses/latesthttps://www.ohloh.net/p...
>
> > > It shows that web2py code has less comments in code (in %) then Django
> > > by a factor 2, but more than TG (+10%). We have more HTML than both of
> > > them. The total code base is not as small as I though compared with
> > > Django. Including the HTML we have more lines of code.
>
> > > Massimo

-- 
You received this message because you are subscribed to the Google Groups 
"web2py-users" group.
To post to this group, send email to web...@googlegroups.com.
To unsubscribe from this group, send email to 
web2py+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/web2py?hl=en.

Reply via email to