Programming advice NOT to follow

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
User avatar
aaronhall
DevNet Resident
Posts: 1040
Joined: Tue Aug 13, 2002 5:10 pm
Location: Back in Phoenix, missing the microbrews
Contact:

Programming advice NOT to follow

Post by aaronhall »

Pulled this off of reddit today -- a top ten list of common programming practices that the author thinks we ought not necessarily follow. I found a couple of the items interesting, and besides that, I thought we could get a nice little flame war going here on at least a few of the points :wink:

http://www.chrylers.com/top-ten-of-prog ... not-follow
User avatar
superdezign
DevNet Master
Posts: 4135
Joined: Sat Jan 20, 2007 11:06 pm

Post by superdezign »

:lol: I hate top ten lists because, oftentimes, they are written by random people who claim to be "experts." Almost any top ten list that I see online is extremely objective and shows little research -- just their personal experience.

Howeeever..

I like this one. Not everything, but number 1, 2, and 6 in particular.

1) Design first, then code.
I agree. When I code, I hate the plan it out first. I'm fine with planning out a website layout before writing the CSS and HTML, and I'm fine with drawing out storyboards before animating. However, when programming, this doesn't work. Every once in a while, I may stop programming and write afew notes on how I feel classes should communicate, but those notes are never more than three lines in Notepad.
When you're not coding, you're wasting time thinking. :-p

2) Code everything early.
Well, thats the summary of it. I agree that oftentimes, I'll be writing a class and simply don't feel like writing out every function. Sure, it will be able to do a whole lot more things, but for now, it isn't. I need the classes to be able to interact for the function I need to test, and thats it. I add the rest as I need it. I'm not developing for a community, and even then, the developers add things as they see fit.

6) Write lots of comments.
Oh, sooo agreed. I compared code with comments only on long pieces code with code that had comments on every single function and different operation, and gahh. Less comments are cleaner than too many. Code is more graceful than English, IMO, and comments only server to shorten the "skimming" process. ^_^
matthijs
DevNet Master
Posts: 3360
Joined: Thu Oct 06, 2005 3:57 pm

Post by matthijs »

superdezign wrote::lol: I hate top ten lists because, oftentimes, they are written by random people who claim to be "experts." Almost any top ten list that I see online is extremely objective and shows little research -- just their personal experience.
I'm sure you meant subjective :)
Post Reply