Over the last 10 years my only occupations have been coding and tutoring! I’ve still got a long way to go to improve my own programming skills but I’d like to include here my honest opinion about what makes a great coder. I’ve gone through a whole series of happy and sad coding stories, I’ve met and worked with hundreds of programmers and students and this is what I’ve found out about the best coders:
1) They know at least one programming language in great depth
Programming is fun, and as soon as you get to scratch the surface and to understand the basics it’s very easy to be tempted to jump to another one and again just learn it superficially. Going from beginner to master requires you to go through the more difficult aspects of a language. For example, in C you might feel tempted to stop after learning about pointers or memory allocation since they feel comparatively difficult when compared to other basic things you’ve learned in the language such as arithmetic and control structures. This becomes even more apparent when one starts to learn about signals, I/O and processes.
Try to be a master in at least one programming language. It will also allow you to land a great job at a great company especially since programming is becoming more and more a required skill in the job market (and not only for software engineers).
2) They know how to debug
While tutoring, I’ve found out that one of the most overlooked aspects of becoming a code master is debugging. Debugging is the process of getting rid of as many bugs as possible. When you’ve spotted that your code doesn’t give the expected result even though it compiles, you can modify the code by adding print-like instructions that give you an idea about the values that flow through the program.
Working with prints is tedious and it requires you to compile, assuming a compiled programming language, and modify the source code every time you get a new idea about what might fix the problem. Believe it or not, the latter is worse than the former because of a well known law in physics that also applies to computer science: “You might modify the outcome by measuring it.” An example of this might be that you can get a segmentation fault in the print instruction itself or, when evaluating the printed expression, there are side-effects.
3) They learn about the operating system
Operating systems are extremely important. If you program mostly on Linux/Unix-based systems, get used to the main mechanisms of your operating system. If you don’t, start by installing or emulating a Linux in your computer. A good way to understand more about the OS is to use the console instead of the graphical interface. After a while, you can try to automate some simple tasks you do and that make you waste lots of time, such as repetitive clicks on a boring webpage, or you can build your own file-server, which is the equivalent of making your own Dropbox or Google Drive, etc.
4) They learn about computer architecture
Programs don’t run in a vacuum. They depend on the processors, volatile memories, persistent memories and other input-output devices they are connected to. A great coder understands the underlying mechanisms of the modern computer architectures enough to make his/her programs run 10-1000x faster depending on the problem being solved.
There are simple optimizations that can hugely improve program performance. For example, just by grouping computation so that the maximum number of operations is done on a chunk of contiguous data that is able to fit into the fast memories available in the processors can bring factors of execution speedup. There is no explicit instruction to the processor that you have to use to employ data in an efficient way. All the data movement happens transparently to the programmer but the program speed is affected by how data is managed by your code.
Speed can be achieved also by explicitly using special programming constructs for efficiency such as in the case of parallel computing. Great coders nowadays use parallel programming models such as OpenMP, MPI and CUDA to benefit from distributed and shared memory multi-processors and Graphical Processing Units (GPUs). Additionally, well consolidated fields such as computer graphics, or machine learning already have Domain Specific Language (DSL) where the performance aspect can be handled more implicitly because, under the hood, code for multiprocessors and GPUs is being automatically generated. This is only possible thanks to the computer domain knowledge embedded in these DSLs. If you want to be a great coder in a domain like machine learning, for example, it’s good to know in detail at least one API or DSL such as Tensor Flow or PyTorch.
5) They learn functional programming
This is one of the most challenging aspects especially if you’re coming from an imperative programming background. Functional programming comes from an initiative to design programming languages in a top-down way. There is a great tradition of making programming languages bottom-up, starting from how the machine works and exposing the hardware complexity to the programmer. The top-down approach asks the question, “What is the most desirable way of expressing computation?” It turns out that the programming languages research community seems to strongly endorse functional programming as the answer to that question. It all boils down to the mathematical way of doing computations using the Lambda Calculus but with syntactic add-ons (also called syntactic sugar), as in the case of the Haskell programming language or non-pure functional programming languages such as OCaml or Scala.
Functional programming is very useful to learn to understand what high quality code is. It’s not just important to write fast, power-efficient or even well-tested code. With functional programming, very large and stable coding projects can be achieved. If performance is too much of a concern, functional programming constructs can still be used in hybrid programming languages such as Scala or in imperative languages such as Python (which borrows functional aspects, like lambda functions, that are functions without names).
Computer science tutoring has increased dramatically since Cambridge Coaching was founded. It has become one our most popular subjects and we’ve been able to recruit some of the most talented doctoral candidates and software engineers to join our team. Many of our tutors are passionate coders, who love to share their computer wizardry with students. We routinely work with high school and undergraduate students looking to hone their programming skills in both customized tutorials, or alongside a course. If you are interested in learning to program, conquering the AP or GRE, or preparing for a career in technology, we can help you.
Check out some of our other blog posts on computer science below!