• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

lines of code / number of classes

 
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the brief certification description there is mention of 3500 lines of code being the average for sucessful assignments.

My question is what constitutes a line of code?

comments?
just a brace?
blank lines?

how many here for example:
<code>

</code>

personally I'd say 1.

On a related point what constitutes a class for similar code stats quoting purposes?

source files only?
all nested classes?
all top level classes?


Thirdly, how many lines and classes (& define these please) have you produced / are likely to produce for your submission?

TIA
 
Author
Posts: 36
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Mike
I don't know about whether the code you present is one line or four (comment, code, space, code). I vote for four! Space is important...(It's also ASCII 032--code!).

I think that environments that try to make object-oriented developers feel guilty because they haven't produced a certain number of lines of code are 1) incoherent and 2) evil. I had a CIO who was interested in that once.

I stress _had_.

One can get 6 or 7 lines of code out of an if/else block or 1 line that does the same thing using the ternary operator. So it's not something I think about.

But I did get worried that I was doing too much when I saw (I think on Sun's site) that 3000 lines of code should be about right. I turned out to have about 10000 lines in 75 or so classes. I know a guy who passed with 20 or so classes.

Of course, Sun also says that it shouldn't take more than 100 hours. I spent far longer on it than that.
[ June 24, 2004: Message edited by: Eben Hewitt ]
 
mike acre
Ranch Hand
Posts: 197
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
And I take it you passed?

I'm sure mine will tend to the larger side of the code volume distribution.

Certainly I shall be spending a great deal of time over it. I can't afford to fail it at those prices!
reply
    Bookmark Topic Watch Topic
  • New Topic