Sign up ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free.

I am obsessed with good code practices, clean code and most of all secure. I often find myself searching for the best way to do something, constantly asking for code review and looking for ways to improve my code. In practice I can manage (been doing PHP for a couple of months) but the theoretical part is my weak spot. I know what most of the concepts mean, I understand them but if someone would ask me to explain something I often find it difficult. This means that if I were to look for a job and the interviewer would ask me questions, they would immediately think I don't know much about the subject.

Is this going to be a big disadvantage for me? Should I seriously start to learn the theoretical part more?

share|improve this question

closed as off-topic by Ixrec, MichaelT, durron597, enderland, gnat Jun 5 at 22:01

This question appears to be off-topic. The users who voted to close gave this specific reason:

  • "Questions seeking career or education advice are off topic on Programmers. They are only meaningful to the asker and do not generate lasting value for the broader programming community. Furthermore, in most cases, any answer is going to be a subjective opinion that may not take into account all the nuances of a (your) particular circumstance." – Ixrec, MichaelT, durron597, enderland, gnat
If this question can be reworded to fit the rules in the help center, please edit the question.

+1 because we could all do with learning more theory – Gary Rowe Nov 15 '10 at 13:11
+1 For for recognizing an area to improve in. – Michael K Nov 15 '10 at 13:15
You need to know the platform well to write code well. Otherwise, you may end up re-inventing the wheel – PradeepGB Nov 15 '10 at 17:21

6 Answers 6

Just remember there is not "right" way to do something. There are many wrong ways, many ok ways, and a few good ways to solve most problems. I will get knocked for this but the ROI for perfect code is not worth it because it doesn't exist. Only good code and bad code. As a programmer you have to strive for the best code quality you can in the time given. How much it pains me to say it, we are in the business of shipping software. If we don't we don't make money. Before I kill your spirit, striving for perfection is something you should always do just don't let it get you down if you can not always get there.

I will get off my little box now and actually answer you question.

I was much like you on theory. In college I was great in my practical classes but always had trouble with the theory classes. This was because during college, I did not see the importance of it. Now that I work in the real world, it has become clear as to why it is important. Knowing the theory behind a subject makes it easier to know if you are going down the right road when solving a problems. It allows you to work at a higher level than code (more general) when working through a design of a system. If you think only in code, it is possible to become short sighted with solutions.

Are you doing it wrong? No. You have noticed an area you could be better in. You have done the hard part and that is seeing an area you could be better in. Keep it up. The development community needs more people who care enough to get better.

share|improve this answer
+1 for community needing more people who care enough to get better – Gary Rowe Nov 15 '10 at 13:12
"piratical classes" did you school not do ninja classes then? – Froome Nov 15 '10 at 14:30
@Aidan: you know pirate > ninja. So yeah. Deal. oh yeah, fixed to be correct word. – Tony Nov 15 '10 at 15:19

Congratulations, you identified an area of need in your career. We all do it, what draws the line between good programmers and the only mediocre is what you do with that identification. The mediocre ignore it, saying "I'll figure that out if I ever need to", and happily bungle their way through their career, not caring about how or where they could be getting better. Good programmers take time and work to patch the gap in their body of knowledge, to become better at what they do.

So what that you don't understand theory. Now's the best time to start learning! Do a quick search, or ask a question here about what books you should read -- you'll have a dozen awesome examples by lunch. The only person who can help you improve is you.

share|improve this answer

I will refer you to an excellent thread on this a few days ago Do I need to understand algorithms and data structures to be called a programmer?

share|improve this answer
Thanks a lot for this link! – Mahmoud Hossam Jan 18 '11 at 6:59

I know what most of the concepts mean, I understand them but if someone would ask me to explain something I often find it difficult. This means that if I were to look for a job and the interviewer would ask me questions, they would immediately think I don't know much about the subject.

Why couldn't you just articulate your interpretation of the meaning behind the concept? I'm asking this because while I may sometimes think I understand something the real test comes when I try to teach someone else the same concept. Another idea would be to discuss some of the theoretical knowledge with someone that may help you when it comes to discussing it if just the articulation is your problem.

share|improve this answer

in my opinion, it's not really that you're doing it wrong. You're saying "I am obsessed with good code practice" but before writing some codes, it's better to understand the concept. Understanding the concept means you know about the subject and you can explain it to others. Sometimes when i'm in a situation like this, let's say for example i should explain that A=>B=>C=>D, i'm explaining first about why C=>D, then why B=>C , A=>B then i find the explanation for the A=>B=>C=>D. Sorry if my response did not answer you question

share|improve this answer

In being obsessed with good code practices you must understand why they are good in comparison to the alternatives. So by understanding what is bad, you are better placed to understand - and therefore explain to others - what is good.

So, you must learn the theory. In doing so you will learn different approaches to problems that cross-pollenate into other areas of your programming life.

share|improve this answer