How To Write Unmaintainable Code 437
An anonymous reader writes "Make sure you're irreplaceable -' In the interests of creating employment opportunities in the Java programming field, I am passing on these tips from the masters on how to write code that is so difficult to maintain, that the people who come after you will take years to make even the simplest changes. Further, if you follow all these rules religiously, you will even guarantee yourself a lifetime of employment, since no one but you has a hope in hell of maintaining the code. Then again, if you followed all these rules religiously, even you wouldn't be able to maintain the code! You don't want to overdo this. Your code should not look hopelessly unmaintainable, just be that way. Otherwise it stands the risk of being rewritten or refactored. '"
Jeez, just run an obfuscator (Score:5, Informative)
Also, see this link with essays. (Score:4, Informative)
Code Obfuscation (Score:1, Informative)
TheDailyWTF.com (Score:5, Informative)
This is ancient... (Score:5, Informative)
Old old old (Score:5, Informative)
Roedy Green's fine How To Write Unmaintainable Code has been widely cited all over the web since its original publication in 1997. Surely at least a mention of the author and date of the article could have made the front page, so that those of us who've already seen it multiple times could know to skip it?
I've seen this over and over (Score:1, Informative)
Re:Lifetime aint always that long (Score:5, Informative)
I worked for a rather large ISP who in the process up and switched from a rather large home grown custom database program it had used for years to the corporate Vantive which cost them millions at the time.
I asked my manager why would they bother doing such a thing when the old program worked just fine. He said "The guy who made the program died and know one knows how to code for it."
I laughed for a moment and then by his blank face realized he wasn't joking...
Re:The Daily WTF (Score:3, Informative)
I'm with you.... (Score:3, Informative)
Another benefit of coding to for a bus is that after a couple of successes, the people you work for will soon start to just take your word for it when you tell them that you should spend more time on a piece of code because it needs to be done right.
I was the 4th or 5th contractor they had for this job, and each of the others lasted long enough for one to two applications before things started to fall apart. I am 6 years into this contract, and on application 17 or 18.
Integrity has been very profitable for me.
Re:I can. (Score:3, Informative)
(1) It's much nicer to have money than not to. I'd rather shop at Gelson's or Whole Foods than Ralphs any day. It's just plain fun to go to nice places and be able to afford nice things.
(2) During this time, I worked for someone who was not very nice. Doing so can severely damage your life and happiness level, no matter how much money you earn. At the same time, working for someone who's not nice is a lot better when you have lots of money and can enjoy yourself outside of work than it would have been if I'd been paid little.
(3) For most of this period, I was unable to find a girlfriend. Again, that's a worse problem than not having money. But at the same time, it's far better to have money and no girlfriend than it is to NOT have money and still have no girl.
(4) I no longer work for the mean guy. I work for some nice people now. But I do it in Pittsburgh, PA, an area I detest. I don't like the cold, I don't like the poor quality services and lack of interesting singles compared to LA, and so on. I'm still not happy, but for reasons unrelated to money or my boss.
So overall, I would say that I am far happier when I have money than when I don't. And I've been in both places, believe me.
In order to be happy, it is necessary to have a balance. You have to like where you live (as I did in LA), like your work (as I do now) and have a companion of the sex you desire. If there is no balance you will not be happy even if you're making US$1m a year.
But on the whole I would say you'd be happier than people who don't. The money lets you have a life away from your problems, and gives you at least a somewhat better shot at the girl.
Hope that helps.
Obligatory link .. (Score:2, Informative)
I smile every time I read it.
Re:I can. (Score:3, Informative)
And being able to resolve it by tossing some money at it gives you time to deal with all the larger problems that money can't resolve.
Pug