Lately, I’ve been reflecting on what it was like to be a beginner; from knowing absolutely nothing about programming to spending over 16 years of my life doing it professionally. As a result, I felt the need to sit down and write about my first experience programming, along with why and how I did it.
Allow me to travel down memory lane (while listening to I Miss 2003) to when I was introduced to programming. At the time, I thought my career would be in music education. I was talking about all things guitar, music theory, and studying every note written and recorded by Randy Rhoads, Jake E. Lee, and Zakk Wylde.
I was fortunate to become friends with someone in my freshman year of high school who was as avid a gamer as myself. By the time we were sophomores, we were playing games at school and having game nights. One day we finally decided to try to make our own game! I focused on learning programming while he focused on designing the game and creating art.
I went home that day and searched, in several different ways, “how are games made?”. We wanted to make a top-down shooter (classic, right?). This ultimately landed me at cplusplus.com (at the time it looked more like this). I was so intrigued by the concept of programming after printing “Hello, World” to the console that I would spend most nights learning, writing my own small programs, and trying to stay awake in classes the next day; all I wanted to do was program games.
Soon after learning the fundamentals of C++, my next quest was to figure out how to display graphics on the screen. My searches led me to DirectX. Keep in mind that I had no idea what I was doing, so as soon as I found something that I could use to draw graphics on Windows, I assumed that was the only path forward and went with it full speed.
It wasn’t pretty. Learning DirectX just after C++ was daunting. I started with drawing a single red pixel on the screen, which was a huge accomplishment because along with this I was also learning about how window management and event flow works in Win32.
Fast forward, we did make the game and I continued to write and learn more about C++. The more I learned about the language, the closer I got to the hardware to better understand the low-level details of how computers work.
At this time, I didn’t know about garbage collection, as I was used to managing memory myself. I didn’t know about managed code and runtimes like .NET, JRE, etc. I also assumed all programming languages let the developer choose the paradigm they want to use for a given project. I didn’t discover until much later in college that wasn’t the case.
What I enjoy about C++ is it’s BlaZinglY FaSt™️ and allows you to do practically anything you want. Of course, this means you can really make life hard on yourself (and others) if you’re not careful, but well worth the trade-off in my opinion. It provides low-level control and expressive freedom; a simple language with tools I can use to build my own abstractions when I think it’s necessary.
It’s August 2022 and we’re now in the race for what will eventually replace C++. Will everything be re-written in Rust, or will Google’s Carbon indeed be the successor to C++? Who knows, maybe it will be something entirely different, but I look forward to seeing how it all unfolds.
The major takeaway from my journey is that learning programming is ultimately a means to an end. Programming for the sake of programming is aimless. Start with what you want to make, and learn what you need to make it.