How to be a good programmer
Hello Folks, It's me again D
A screen of emacs programming session
I have met people who asked me how to become a good programmer. Where to start. This is difficult question to answer. One programmer can give different advice than another. It depends on the experience. So I'll share you my view about being a good programmer, and where to start.
First of All, learn Computer Science
This is mandatory for you. Languages is nothing without algorithm. Language is nothing without logic. And you'll be get real trouble when you don' understand logic gate when try to do some binary data processing. How come you know that 4 or 2 = 6 and 4 AND 2 = 2. Sure you can try them on your console. But it's really convenient if you understand it. You maybe satisfied with Bubble Sort, but did you know that you can do it faster using Merge Sort or Quick Sort. And do you know to seek for shortest path on your map you need graph traversal? All of them are studied in computer science.
It'll make you better programmer than people who learn that the hard way. Trying something and error. You can prove that your algorithm is best to your peer by counting big-O notation. Why you must use an array of boolean when you can do it simply with bitwise operation on an integer. This is what you get when you learn CS.
Second, learn some math and/or physics
I don't mean you need to be a mathematician to do programming. But math really helps to solve problems at hand. My background as game and web programming make me realize that math is just a toy. If you're doing game like me. Learning some physics will help you to create immersive scene. You want to make some Javascript effect like this, you need Verlet Integration. Math also help you with complex problem. By calculus simplification for example. And you can do cool things with matrix calculation. No game made without it.
You may want to be a champion engineers like Google. But you won't if you don't understand simple mathematics.
Third, learn a language that drive you to understand your computer well
I am a definitely Python programmer. But yet, I don't recommend it for you when you start learn programming on your college. Since what? Python has magic! And those magic make you far away from the essential of programming. It's really easy to do dynamic array or linked list in Python without even knowing what is happen on the memory.
My recommendation will be C. Yes C, no ++. Plain C. I found that this is the best place to learn about your computer. The language is simple, no magic. Especially since C give you freedom on managing memory which also means you must be responsible on managing it well. It makes you intimate with your computer without need of getting deep in non-portable way, eg writing assembly. You will also learn how program compiled to object code and linked to library to make final executable like you learned on CS class. C compilers is available on almost all platform, even for iPhone or iPad.
Once you know C well, I bet you can learn another imperative language well. E.g. Python, Java, Objective-C or another 'hip' language. C is the old language that I've known. But this language is the most lasting language. It's used almost on all platforms and operating systems, even microcontroller. You can extend your convenient scripting language with C if you want. If you learn from scripting language then you'll have no clue if you need some features that can't be accessed by the language interpreter. For example, you want to know your processor id.
Fourth, make a product, or contribute to open source project as a programmer.
This will really help you on understanding programming deeper. Create a product based on your knowledge, publish it. And best of all make it opensource! If you are fresh graduate. Releasing your code as open source project will help you much. You'll get inputs from your peers. Or you prefer to contribute to existing open source project? That's also great. The step is checking their code, try to build it. Opening the bug tracker and then try to fix the simple bugs.
I see almost nobody here, in Indonesia, contribute back to open source community in the form of CODE. Believe me, contributing back, even a small thing make you better programmer, since you'll learn how to collab with other people, how to patch repository, how to send patch, how to discuss bugs, etc etc. It's really useful.
Last but not least, LEARN ENGLISH
Yes I make it bold, caps, and red. Since to be honest, I really fed up of people so lazy to learn english. At least learn english to the extent you can read the programming books. Computer innovations mostly starts from Silicon Valley. You expect them to write books in Bahasa Indonesia? But if you understand what I've written here, then you do understand English :)
Being a great programmer is not an easy job. You need to keep improving and read a lot of books if you don't want to be left behind. Don't settle on what you feel 'comfortable' now. Read news, read trends, and improve your skill by learning them.
