Ten Lies Programmers Tell Themselves

HardOCP News

[H] News
Joined
Dec 31, 1969
Messages
0
Ten lies programmers tell themselves? I don't see "chicks totally dig programmers" on that list anywhere. ;)

Of course, people in every profession lie to themselves now and again. Some jobs, though, like ones where people work alone for long stretches, such as writers, programmers or toll booth operators (I'm guessing), seem more prone to it than others. No matter how much it occurs, every occupation has a common set of lies that its practitioners tell themselves. Here now is a list of 10 lies that programmers often tell themselves.
 
Some of these lists are really terrible. This one is eerily accurate.

Except for the Halo 4 references. Unless they released Halo 4 on linux and I just missed the announcement.
 
So any of those remind me of Windows 8...

I don't document really anything ever however... but then again I don't work with anyone else so they don't have to get "the system" (plus in some things it's kind of better they can't...
 
I can't believe they dragged toll booth operators into the same heap they put programmers into! :( Why would they randomly drag innocent people down along with them.
 
This code is self-documenting
This is the worst one. Some code is simplistic enough to be largely self-documenting, and descriptive naming schemes help with that (not calling every vector you make "v", and not senselessly shortening names like "isComplete" to "comp"), but a great deal of the code that gets written on a daily basis is not self-documenting. There's what the code presents, which is generally self-explanatory so long as arcane techniques aren't used, but what the core concepts of what that code does and how it fits in with the rest of the application generally are not. Doing good documentation takes time, but it doesn't hurt performance, doesn't bloat executable size and doesn't negatively impact anyone in the event that it's unneeded.

The worst lie, though, is uttered by those who believe that mysterious, complex and tricky code is what's best. Incomprehensible structures and techniques used to eek out mostly immeasurable performance gains, or just to be weird and different than anyone else. No one else can understand it, and that's what makes it somehow great.
 
#11 I don't have to communicate to anyone but my boss. It's his job to communicate to everyone/anyone else.
 
That was retarded.

Wtf was with the halo 4 bs anyway?
 
This is the worst one. Some code is simplistic enough to be largely self-documenting, and descriptive naming schemes help with that (not calling every vector you make "v", and not senselessly shortening names like "isComplete" to "comp"), but a great deal of the code that gets written on a daily basis is not self-documenting. There's what the code presents, which is generally self-explanatory so long as arcane techniques aren't used, but what the core concepts of what that code does and how it fits in with the rest of the application generally are not. Doing good documentation takes time, but it doesn't hurt performance, doesn't bloat executable size and doesn't negatively impact anyone in the event that it's unneeded.

The worst lie, though, is uttered by those who believe that mysterious, complex and tricky code is what's best. Incomprehensible structures and techniques used to eek out mostly immeasurable performance gains, or just to be weird and different than anyone else. No one else can understand it, and that's what makes it somehow great.

The problem though with correcting so called "self-documenting" code is comments, and quite often, I've noticed that the code is more readable as to what it's trying to do than the comments.

I can't tell you how many times I've seen comments which were copy and pasted, not having any reason to be in the portion of code they're in, or how many comments are way out of date, etc.

If the comments are longer than the actual function, then there's something wrong with the function. I'm not talking about self documenting code here, but it should not be obfuscated enough that any halfway decent programmer can't figure it out within 30 minutes. That's just bad coding otherwise.
 
Good documentation isn't commenting, nor is it generated from comments (like Doxygen) — good documentation is external to all of that, so it doesn't pollute the code itself. Realistically, what you want is something like a wiki, where it's explained what different classes/objects are, what their purpose is, how they fit together in terms of the application and how their interfaces are used. The low-level details are mostly syntactical, and any language reference can explain them, but the high level is what requires documentation. When you need to understand reasoning, purpose and interfaces at a high level, that's when you want to reach for documentation, and that's why it should be there.

I see code comments as a way to guide people through rough terrain. If there's an oddity, or if some snippet needs explanation, then short comments are there for you to help you understand certain small blocks. Over-commenting does lead to an annoying codebase to work with, and most people don't know how to properly comment. These are just educational issues, and they're small obstacles. It's the "no documentation required" mentality that's more the problem, and it's pretty pervasive.
 
#1... I'm a programmer so I can design the user interface myself as I go along.
 
Good documentation isn't commenting, nor is it generated from comments (like Doxygen) — good documentation is external to all of that, so it doesn't pollute the code itself.

No, that documentation is terrible and guaranteed to be out of date even faster than comments are - and comments become out of date pretty darn quick.
 
If it can go wrong, it will go wrong.

Wait, that's a lie programmers tell themselves? So everything is peachy and nothing ever goes wrong in programmer town, everyone just worries about it going wrong? :D
 
A guy from my work was just like this when he was programming. He took over development of the ticketing system we use at work (note...not designed) and not only was it buggy as hell but every time I mentioned I had a problem, he would say "it doesn't happen to me, must be your computer". As I am a programmer as well, this pissed me off quite nicely.

Luckily he has moved on to field work, yay!
 
#1... I'm a programmer so I can design the user interface myself as I go along.

User interfaces are an art. But this has more to do with management and the people who make the choices than it has to do with the programmers. Functional != good, and all too often, the UI is horrible. I have to give Apple credit in that they seem to understand this for the most part. Unfortunately, many (I'd say most) do not, and we end up with terrible UIs because the programmer is good enough to create it. Would you skimp on your budget to have your programmers draw your graphics or make the music? I think not.
 
I used to do QA and damn the programmers were assholes at times. I've found issues where I suggested changes and they were like "Fuck no, it's a waste of our time." I was thinking from the customer's perspective and not the programmer's perspective so I've always thought that would be helpful to our customers. Glad I don't do QA anymore.
 
I used to do QA and damn the programmers were assholes at times. I've found issues where I suggested changes and they were like "Fuck no, it's a waste of our time." I was thinking from the customer's perspective and not the programmer's perspective so I've always thought that would be helpful to our customers. Glad I don't do QA anymore.

While many programmers have god complexes (and I'll admit, QA isn't viewed very high on the totem pole), you also have to understand that they're quite often treated like assembly workers. Everything needed to be done yesterday, which leads to a distaste for anything that will add to their plate. Then you get to the area of how often people hear suggestions (many of which are just infeasible) to the point that they honestly don't care what others think anymore.
 
User interfaces are an art. But this has more to do with management and the people who make the choices than it has to do with the programmers. Functional != good, and all too often, the UI is horrible. I have to give Apple credit in that they seem to understand this for the most part. Unfortunately, many (I'd say most) do not, and we end up with terrible UIs because the programmer is good enough to create it. Would you skimp on your budget to have your programmers draw your graphics or make the music? I think not.


Well, I don't see why a programmer can't do a UI or graphics or music if he has the skills for that. People aren't good at only one thing and some may excel in many (I've met Software Engineers that were fantastic coders and also played instruments professionally).
 
Wait, that's a lie programmers tell themselves? So everything is peachy and nothing ever goes wrong in programmer town, everyone just worries about it going wrong? :D
I think he misunderstood what the article was about.

No, that documentation is terrible and guaranteed to be out of date even faster than comments are - and comments become out of date pretty darn quick.
This seems like an excuse a lazy developer might offer as to why they don't document anything. Ironically, the excuse itself doesn't mask their laziness, as the excuse itself involves it.
 
man, i use the one about being the only one to know the code a hell of a lot...then again, it wouldn't exactly be a punishment if this particular place laid me off.
 
Lol

"Naa, we don't need to replace/update the code just because (the main programmer) left - it still works right?"
//Fortran or COBAL from the 70ies
 
I see programmers being more of PC gamers and not Xbox 360... Just Sayin! :8)
 
I’m the only one who knows this code, so they can’t lay me off - They’re lucky I don’t demand a raise.
Yet at the same time...
This code is self-documenting - No need to write separate documentation; it’s obvious to anyone with a brain what this code is doing.
 
When I’m playing Halo 4 I’m thinking about coding, so it’s like I’m coding - First person shooters help me to think through complex programming problems.

In some instances, when a bug appears, if you understand coding, you can generally understand WHY it occurs at a high level. Good programmers do this all the time.

I’m the only one who knows this code, so they can’t lay me off - They’re lucky I don’t demand a raise.

Well, not true for C based languages. But for COBAL and APL (still in use in the financial industry) and other lesser used languages, guess what? This statement is still true. And yes, these programmers can and do demand raises from time to time, and due to lack of knowledge in both the language and the program, they usually get them too.
 
User interfaces are an art. But this has more to do with management and the people who make the choices than it has to do with the programmers. Functional != good, and all too often, the UI is horrible. I have to give Apple credit in that they seem to understand this for the most part. Unfortunately, many (I'd say most) do not, and we end up with terrible UIs because the programmer is good enough to create it. Would you skimp on your budget to have your programmers draw your graphics or make the music? I think not.

Where Apple got it right was in 2 area's.

1. Provide a development environment that provides tools to create a consistent, human friendly UI across the OS and all applications.

2. Instill the theory that the best applications will always have their complete user interfaces created before coders are allowed to write a single line of code, and that code must be written to the established user interface.

IMHO, user interface design and application coding are two distinct professions that should not cross paths.

Anyone who remembers The Inside Macintosh library of books (especially the original phone book version) and the Macintosh Human Interface Guidelines book, understands all this.

I have full belief in this process today. Hate te company if you wish, but the really had their shit together when it comes to te UI.

For the most part they still do, however I do feel the move to MacOS X diluted the philosophy, if only by a small amount.

It's underpinnings may have been become in a bit creaky (we can tank the PowerPC conversion for that), and replacement may have been inevitable, but MacOS Classic, from a UI and usability standpoint, was frickin' beautiful and brilliant.

Microsoft gets absolutely NONE of this. Their human interface design appears to b run by the former designer of the Pontiac Aztec.

I will give them one win. The menu bar. I believe each window is better served by having its own menu bar instead of a single bar system wide. However we have to remember that the Mac philosophy was developed in the early 80's where 128k of ram was going to be te norm for a while. Resource conservation was paramount.

What they accomplished with 128k of ram and a 400k floppy drive was brilliant.


Alas, Microsoft has seen fit to even screw up its win in the menu bar department :(
 
I've never said any of this to myself... but then I only program for a hobby, so I guess that list is only for people that program for a living?
 
I've been writing software professionally for 30 years and I can honestly say that the "self documenting" code lie is the worst and still most prevalent. Sure anybody with some skills can read the code and tell WHAT it is doing, but the WHY is missing. That's what documentation is for. Having worked for big companies like IBM and Medtronic, was well as smaller ones most of you have never heard of, it's my opinion that only high level architectural type documentation should be external to the code. Everything else should be in the code; that's the best way to ensure that it is kept up to date. And on that subject, comments should always be updated when code is changed. If you don't do that then you are neglecting an important part of your job. This should also be part of the code review - to check for updated comments. But that's another subject I suppose.
 
I've been writing software professionally for 30 years and I can honestly say that the "self documenting" code lie is the worst and still most prevalent. Sure anybody with some skills can read the code and tell WHAT it is doing, but the WHY is missing. That's what documentation is for. Having worked for big companies like IBM and Medtronic, was well as smaller ones most of you have never heard of, it's my opinion that only high level architectural type documentation should be external to the code. Everything else should be in the code; that's the best way to ensure that it is kept up to date. And on that subject, comments should always be updated when code is changed. If you don't do that then you are neglecting an important part of your job. This should also be part of the code review - to check for updated comments. But that's another subject I suppose.

I agree. Back in the 80's I developed database systems using Clarion Professional Developer. While a lot of what I did I did manually (it was very Pascal like in nature), it was Los a code generator and it would self comment the code.

I used it to develope the user interface modules because it was exceptionlly good at it.

But the commenting, while technically accurate, has no way to really what te developer is thinking.

This is where design specifications come in. I used to keep one for every procedure, function and main loop I wrote.

I wasn't even a pro dev and I knew to do ths basic stuff.
 
Probably be more accurate to name the article "Ten lies bad programmers tell to themselves" :p
 
This seems like an excuse a lazy developer might offer as to why they don't document anything. Ironically, the excuse itself doesn't mask their laziness, as the excuse itself involves it.

It has nothing to do with laziness. If the documentation is external to the code, you don't think about it when you are busy editing that code that invalidates the documentation (or heck, you may not even know such documentation exists, where to find it, or how to edit it). Putting very tightly coupled things in two completely different places is just idiotic.

Comments and inline documentation (javadoc, etc...) getting out of date is arguable more about "laziness", but I'd still disagree with that. It's closer to the code being changed and it at least moves with the code most of the time, but it still tends to be an "out of sight, out of mind" thing.
 
Back
Top