Disclaimer
I am on a mission to compile a list of random thoughts on computer programming. Below is the start of that list. Most if not all of these thoughts have been expressed before, but I had to put my twist on them. I welcome your feed back. And if you want to add a random thought then that is even better.
Don’t be a poser. If you don’t love computer programming then do something else for a living.
If you have never been compelled to work on a computer program for 16 hours straight then chances are you do not love programming. I have gone on coding marathons that have rendered me brain dead. There are times when I leave the office at night and can barely remember where I live! Remember the kid who loved writing text based games on the Apple IIe in middle school; that was me. Hell, I traded Mortal Kombat and StreetFighter 2 Turbo Edition for a commodore 64 just so I could program at home. That’s love! If you do not love programming then do the rest of us a favor and quit. The last thing we need is for you to stick around and become a manager.
Don’t over engineer.
This is going to piss a lot of people off, but here it goes. Just because you read the Gang of four book does not mean you have to try and bastardize their teachings to make them fit every project you work on. Think about how a problem should be solved not how you can ho out a design pattern to solve a problem. If you feel the need to show off to your fellow engineers then display the book in your cube for all to see. But please, refrain from feeding your ego by suffixing every class you create with the word “Factoryâ€.Â
Do not use your powers for evil.
While working for a major company I was asked to screen scrape a 3rd party site to solve a problem. At the time I was an inexperienced grasshopper and went to work on a solution right away. In the middle of implementing the thing I had a moment of clarity and thought to my self “What the F am I doing!â€Â Screen scraping is dangerous. What if the 3rd party decides to change the site in the middle of the day? I can write this code, but I shouldn’t. I mean a good surgeon could probably give me horns, but it would be really irresponsible. That day I learned a very important lesson. Sometimes certain solutions are just too risky for prime time.Â
Know when to walk away (Diminishing returns).
I can’t tell you how many times I have left the office at midnight after trying to solve a problem only to have the answer pop in to my head on my drive home. Don’t get me wrong I still go nuts every once in a while. But I have learned that sometimes it pays to walk away for a while.Â
Don’t write it if you can byte it.
If I see one more from scratch implementation of StringUtil I think I may go nuts. And I am not talking Britney Spears “shave my head†nuts. I will go Whitney Houston “Crack is wack†nuts!  If you honestly believe that you are pioneering something by creating a StringUtil then you must also believe that you are the first person to beat Super Mario Bros with one life. The point is before you create something, ask yourself the following questions: Is this a common problem? Has it been solved before? Will the existing solution suffice? Can I maintain or is there a community to maintain the existing solution? If you can answer yes to all of those questions then you have just saved yourself a lot of time.Â
Don’t make crap harder than it has to be AKA KISS.
Which would you rather read?Â
if( str.equals(“a”) )
{
     nextLetter = “b”;
}
else if( str.equals(“b”) )
{
   nextLetter = “c”;
}
else
{
   nextLetter = “z”;
}
Or this…
nextLetter = str.equals(“a”)?“b”:(str.equals(“b”)?“c”:“z”);
Look we all know that you can sling some wickedly dense code. But other than showing off your kung fu skills complex one liners do nothing but piss off the poor sap that has to maintain it. Enough said.
Switch jobs at least every 2 years when you are first starting out.
I have been called a job whore. Okay maybe I am. But let me remind you that most whores are good at what they do! I usually learn a ton the first 6 months at a new job. After that things start to become routine. If you are just starting out then the best way to learn is to job hop. The fact is most companies do not change/adopt new technologies often. So if you want exposure to a variety of technologies you are going to have to change jobs often. I, like most, do research on my own; but nothing is sweeter than getting paid to learn new things. In addition with a new job comes a new circle of programmers to learn from.Â
Don’t lie on your resume or during a job interview!Â
I hate it when people lie during an interview. So much so that my team and I subtract points from candidates who lie to us. If I ask someone a question and they say “I don’t know†then I respect their honesty. I don’t expect anyone to know everything! What I do expect is honesty. No matter how gangster of a tap dancer/BS artist you think you are you can not get away with pretending to know the difference between an abstract class and an interface. And if you want to really rack up some bonus points say “I don’t know can you give me a short explanation?â€Â (If the interviewer says “no†then he/she is a big tool bag and you do not want to work with him/her anyway.)
Language does not matter.
For the most part, if you can code in one managed OO language you can code in any of them. What really matters is that you understand object oriented principles. After all, all you are really doing is creating instances of objects and sending methods to them. Once you understand the basics, all you need is a syntax primer and an API and you should be ready to start slinging code.Â
On a side note I just have to say… I loath it when I get asked by recruiters, “how many years of experience do you have with XYZ language.â€Â I want to fire back with “how many years of experience do you have recruiting for programmers!â€Â Recruiters should focus on finding well rounded developers who write clean maintainable code. Not some dense programmer that is content with using the same language for years on end. Bottom line, spaghetti is spaghetti in any language!
Do not list your current employer on your resume.
I learned this the hard way. One of my friends was a manager at a company I was working for. One day he called me to his desk and showed me an email that went out to all of the managers. It was a copy of my resume along with a note attached that read something like the following: “this guy is looking for a new job. As a recruiter I can help you retain him for a fee.â€Â It turns out that some ass hole recruiter was scouring the internet for résumés and contacting the listed current employer to offer “retention servicesâ€Â That is bar none the shadiest thing a recruiter has ever done to me. As a result of that experience I always list “Company Confidential†as my current employer.Â
Find a mentor. Be a mentor.
Find a Yoda! Be a Yoda! This is pretty self explanatory. Trust me on this one. No matter how much experience I gain I will always seek out someone who can teach me stuff. In turn I pay it forward by teaching people stuff.
You don’t need some overpriced 3 million page programming book to learn something new.
Most programming books are longer than the bible and expensive as hell! In addition I find them to be highly repetitive and often boring. When I want to learn a new technology I use that technology to implement something cool. For example, say you want to learn how to use Adobe Flex. Don’t go out and buy some monstrous overpriced book; instead, bust out a Google search for a short primer and read it. Afterwards, find someone who knows Adobe Flex and pick their brain. Then set out on creating your master piece. And I do mean master piece. You want to keep things interesting. The last thing this world needs is another address book!
Understand the following concepts.Â
• Separation of concerns.
• Encapsulation.
• Inheritance/Polymorphism.
Wield the following tools.
• Debugger.
• IDE.
• Source Control.
• Unit Testing.
• API.
• User Groups.