Physicist to Programmer: bottom-up vs. top-down learning

Two years ago I left a PhD in physics, joined a startup, and taught myself to be a software developer. I had to radically alter the way I learned and approached problems.

An education in physics is very much a bottom-up approach. Before you can grasp the intricacies of electromagnetism, quantum mechanics, and general relativity, you need a firm footing in the fundamentals. I believe this is the right learning model for physics. If you’re trying to determine the underlying truths about the universe, you should have a solid understanding of first-principles.

This mindset, however, can lead to a “Physicist’s ego”: A sense of superiority over those who don’t seek bottom-up understandings. A distaste for black box solutions. As a physics student, I experienced this “ego” in many ways. Contempt for the “plug and chug” problem solving that engineers employed (using equations but skipping their derivations), refusal to use third-party code or out-of-the-box solutions in my research (considering it akin to cheating), and a general opinion that physics was the superior discipline (except, perhaps, for math).

Then I joined a startup as a full-stack software developer with almost zero programming experience. Turns out all those Matlab scripts I wrote for my research did not even come close to preparing me for the life of a software developer. Early-stage startups have to move fast, so I had to learn faster. The bottom-up approach was no longer sustainable or appropriate.

A full understanding of computer science and the intricacies of programming does require a deep level of knowledge. But, depending on your goals, the level of understanding you actually require varies greatly. Modern programming languages consist of layers of abstraction built on layers of abstraction. They are designed to reduce the required background knowledge of the programmer. You should embrace this.

The best way to learn to code is to start coding. This is cliche advice but it’s important to internalize. Do not let incomplete knowledge stop you from starting. Get comfortable using tools before you fully understand them. Your learning style should be top-down. Work down the layers of abstraction only when you need to.

The physicist in me still recoils at this mindset. But, as an approach to self learning, it’s been very effective. Start learning by pattern matching. How did someone else solve a similar problem? How can I modify their code to make it do what I want to? Eventually, the problems you’re solving will become unique or you’ll hit a bug you don’t understand and you’ll be forced to dive a little deeper in your understanding of the underlying technology. You learn to code by coding, but the real learning comes from breaking things and fixing them.

To become a programmer from scratch follow these steps:

  1. Become a copycat: Mimic more experienced programmers
  2. Stay shallow: Learn only what you need to know for your specific problem
  3. Launch early: Start by getting something (anything!) working as quickly as you can
  4. Every bug is a lesson: When you hit a bug, do a deep dive to understand it as fully as you can

One thought on “Physicist to Programmer: bottom-up vs. top-down learning

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s