Let Go, Standard Library From Community

janderson askme at me.com
Wed Apr 18 09:38:16 PDT 2007


Dan wrote:
> Brad Anderson Wrote:
>> Oh to be a fly on the wall when the current lib doesn't have a function you
>> need...
> 
> I can write assembler.  
> I can write D.
> I can write ECMAScript.
> 
> If there's something I need that isn't there, I write it.  I personally think there's something wrong with someone who claims to be a programmer but *can't* solve a trivial puzzle.
> 
The problem is that every code monkey ends up re-writing the same code. 
     That means a lot of time wasted focusing on writing solutions to 
problems that have already been solved.  It also means when reading 
someone else's code there's more to learn, rather then there being a 
standard way of writing something (more time wasted).  Furthermore 
things that have been in some public library (not necessarily standard) 
generally receive a high level of free testing from the community, that 
means I save more time.

My approach to coding is to try to do as much re-use as is feasible.  It 
means I can focus on the actual problem more, not how I get there.

> Not knowing what address to write directly to the screenbuffer is forgiveable.  Look it up.  Not being able to implement huffman compression or a quicksort or binary search, or a jump gate after knowing what you need to achieve... well, that means you lost that gleam in your eye you had back in kindergarten.

I can, have and believe anyone one on this newsgroup could as well.  It 
doesn't mean I should do it again.  Its a time investment, even if it 
only takes you 5 minutes to write a quicksort.

I'm sure Michael Abrash could write a ASM optimized quicksort that could 
rival anything normal people could write (and sure given time any code 
monkey(s) could produce something better).  Even Michael Abrash is an 
avoid code reuser.  That's an advantage of using code that has been 
worked on by a community or been available forever.

That's this code monkey's view.

Humm, although I respect your option:  You should know that this is one 
common interview question.

PS - Yes I'm a Michael Abrash fan-boy.
> 
> - Dan



More information about the Digitalmars-d mailing list