Saturday, June 21, 2014

Brevity vs Flexibility vs .....

Pimp My Code, Part 14: Be Inflexible! - http://blog.wilshipley.com/2007/05/pimp-my-code-part-14-be-inflexible.html

Excerpt:
 In coding, you have many dimensions in which you can rate code:

- Brevity of code
- Featurefulness
- Speed of execution
- Time spent coding
- Robustness
- Flexibility

Now, remember, these dimensions are all in opposition to one another. You can spend a three days writing a routine which is really beautiful AND fast, so you've gotten two of your dimensions up, but you've spent THREE DAYS, so the "time spent coding" dimension is WAY down.

So, when is this worth it? How do we make these decisions?

The answer turns out to be very sane, very simple, and also the one nobody, ever, listens to:

"START WITH BREVITY. Increase the other dimensions AS REQUIRED BY TESTING."
  
 

No comments:

Post a Comment

Followers

Blog Archive