jason.today

On Learning to Code

Friction at the outset

As software continues to have an outsized impact on just about every aspect of our lives, the desire to "learn how to code" has gotten more and more popular in recent years - it feels like everybody is doing it. Coding bootcamps have become quite established, the computer science major has exploded, and there are courses, videos, and books on seemingly every nook and cranny of modern software. The sheer volume of information and the absurd number of ways the same thing can be built causes even weathered developers decision paralysis. Novices can easily get stuck in "tutorial hell". It can feel incredibly intimidating to get started and build things to be proud of.

And if that friction wasn't enough, now there's AI.

It's not the AI we've been seeing for the last 20 years telling businesses what to change, what ads to serve us, and telling us what to buy, read, and watch - no, it's the actual talk to it and it gives you an answer to pretty much anything artificial intelligence, straight out of sci-fi.

That same AI is being used in demos and products to create programs, websites, and games in seconds, that an average developer might take a few hours or days to be able to build. So, it's not surprising that a whole lot of people think AI is going to replace developers.

So is it even worth trying anymore? Should people even learn how to code?

Let me first say - AI replacing developers: it's very difficult for me to believe this is true. Will the developer's job change dramatically in light of advancements in AI? Maybe. Will AI play a major role in software development? Very likely! Will every developer need to use AI to stay relevant? Doubt it. Will everyone be working directly on AI? Absolutely doubt it.

Take, the internet. The internet fundamentally changed software products - what they could do, how they could do it, and thereby changed what many developers build and how they build it. But, guess what. Not everyone is a network engineer. Some software is entirely offline. Many developers have very little idea how fundamental constructs of networking work, and just know to call the right things in their framework of choice in that special way the documentation says in order to make everything work how it should. (This is what abstraction does, and compartmentalizing knowledge through high-level constructs is incredibly useful.) The internet introduced new software architectures and patterns and unlocked entirely new potential types of software, but it didn't change the general steps it takes to become a developer and build the intuition necessary to build software.

Is it a perfect comparison? Certainly not. But I think it helps paint a picture of why I believe developers aren't going anywhere.


Learning a language

I often hear something along the lines of "I want to learn Python" or see an advertisement for a course to "learn Javascript" or even "learn React". And pursuing this learning path can end up yielding results somewhat different than what someone learning was actually hoping to accomplish.

If you memorize most of the words in the English language, without practicing using them and building intuition of how they can be used together, you'll end up unable to read or write, and certainly won't be able to communicate about complex ideas eloquently.

I've seen courses, guides, tutorials, you name it, that teaches in a way that really feels uncomfortably similar to the situation I've described above. It's like, here's how to do this thing in Javascript, ok, now go build this thing. Or worse, "Here's a bunch of code - paste that in, now this bit. And you have a thing!" And sure, that can probably get you somewhere, but if you're not an autodidact, or otherwise comfortable spelunking around the web for why things are the way they are, you'll have a hell of a time actually understanding what is happening in that code you wrote, and how to fix it when it doesn't work.

And honestly, with ChatGPT and equivalents, I'm very concerned for potential learners - it will be easier than ever to fall into this trap. Your AI isn't going to make sure you learn and understand the material like a good teacher would, not to mention it has no deep understanding of what it's talking about and will gladly mislead you, confidently and convincingly. Don't get me wrong - it's transformationally useful technology, but a crutch, or worse, if used improperly. Ever talk to a teacher where they refuse to give you the answer and force you to think for yourself, so you actually learn why something is the way it is? Yeah... ChatGPT won't do that. Feels good in the moment, not great in the long term.

Building intuition around how to create and think about code and systems will be more important than ever, as tools continue to simplify learning language syntax through intelligent tooling. Quizzing Java interview candidates on "final vs. finally vs. finalize" will be even more useless than it was the last few years.

That being said, "Learning a language" like "learning Python", is not just about learning the syntax - far from it. Especially if it's not your first language- the syntax is the easy part. It's about how to use the language to accomplish what you want, which could look completely different from another language, like, say Elixir. Learning a language involves learning how to represent state, how to do multiple things at once (asynchronous code, threading, multiprocessing), how to use the standard libraries, how and when to use popular libraries, all the "gotchas", or even larger differences like memory management or functional, imperative, declarative etc. And then there are the softer things like "the right way" to do things, due to performance or style, and they often have different tooling - how do you develop, compile, execute, visualize, profile, etc.

What's really interesting though, again, ChatGPT (at least GPT-4) is pretty good at helping you with all of the above, either by pointing you in the right direction or giving you an answer directly. Which I can't stress how awesome this is compared to getting yelled at on stack overflow, judged on reddit, left hanging on a community forum, or simply lost using Google, resulting in you just doing it a particular way until you happen to cross paths with a blog post or another developer that knows a better way.


The Start of a New Series

So this brings me back to the importance of building that initial intuition, that foundation of understanding that I believe to be so critical.

This marks the start to a series where I discuss in long form what I believe to be critical foundational ideas to understand and learn about, in order to build the intuition that will act as the foundation for learning to code - for learning to build software. Throughout, I'll take into account modern tooling, and where and how it can be helpful.

It may look reminiscent of my falling sand series, though I plan to flesh it out more. I'm also playing with the idea of doing high production value videos using motion canvas or manim, but they take a wildly long time to make well, comparatively. Curious on folks thoughts. Feel free to reach out to me hi@jason.today with any opinions.

(2024-05-24) Check out the next post in the series, Representation!