I never thought I would become a programmer. I stumbled into web development while I was studying music in college. Believe me, I was surprised when I ended up becoming a professional web developer. Although surprised, I’m really happy with the work I’m doing. I’ve also come to realize, it’s no coincidence that I’m pretty decent at coding — programming has a lot of similarities with music.
This explains why a lot of the great programmers that I meet are or were musicians at one point. I think the two go together very well, and I hope that some musicians out there read this and think about learning to code. I did, and it was most definitely worth it. Not only does it help pay the bills (it’s hard out there for us musicians), but it is fun and challenging in similar ways to music.
Whether it’s a writing feature on a website or finding a good fingering for a piece of music, I’m constantly trying to solve problems. There are always a bunch of ways to solve a problem. Some solutions are better than others. Some are more efficient, more precise, or more tasteful. Some should be avoided because they are inefficient, ugly, or bad for whatever reason. As you play more music or write more code, you start to accumulate a tool chest of solutions. There are a lot of opinions about which are good and which are bad, but in the end, it’s a situational thing. Ultimately, it’s up to you to decide which ones to use. It takes real contemplation to choose the right approach. If you just wing it every time, you’re gonna have a bad time with both coding music and software.
Solving Problems in Music
As I hinted at above, a problem I come across constantly while playing cello is coming up with fingerings. A passage of notes in a piece of music can be played many different ways, with different fingers, on different parts of the instrument. Sometimes you will try to come up with a fingering that involves the least amount of “shifting” (moving your hand up or down the string); sometimes you want one that involves the least amount of “string crossings” (moving your fingers and bow from one string to another). Generally, if you have a fingering that has too many shifts or string crossings, it’s a bad fingering. If you’re using a bad fingering, you probably haven’t really thought about the best solution to the problem. The best solution is oftentimes not the hardest. You just have to spend some time figuring out the smartest way to do it.
Solving Problems in Programming
In web development, I think of most features that I have to implement as a problem I have to solve. Often times it’s a problem that I’ve solved before, so I just reimplement the old solution (just like I would do for a fingering). If it’s a new problem, I have to come up with a new solution. Same as with a fingering, if the solution you have is a pain in the ass to implement on a large scale, it’s probably not the best solution. If it works well, then add it to the tool chest. The more reusable solutions you get under your belt, the faster you will be at solving problems. Which leads to another similarity.
Both programming and music are based off of a bunch of reusable functions, which all serve particular purposes. In music, I think of chord progressions. Each chord serves a purpose. The foundation of a chord progression is called the “tonic” chord; the tonal center of the progression, which is consonant and aurally pleasing. Certain chords are often used to lead to the tonic; these are more dissonant chords, which make the resolution to the tonic that much more satisfying. Then there are chords that lead particularly well to the chords that lead to the tonic. You can always break these rules when coming up with a chord progression (which is oftentimes when things get interesting), but you will be able to write better music if you understand the common functionality of chords. Once you get how chord progressions work, you start to realize that most songs, from jazz to pop, reuse similar chord progressions all over the place.
I’ve always loved this video, which exhibits the reuse of one of the most common chord progressions in a pretty hilarious way.
It is the same way in programming; you can and will often reuse existing functions that were written by other people. You can get away with not knowing everything that’s going on in the background, but if you actually understand how it works, you will be a lot more versatile and be able to customize things if need be.
Similar to chords in a progression, features in a piece of software are broken out into their own set of functions which can then be easily reused when necessary.
Nothing Good Comes Easy
Coding is hard. But guess what, a lot of things are hard. Especially skills that are personally and financially rewarding. I started learning to code about four years ago. When I first started, it was intimidating. Similarly to learning cello, I initially wasn’t convinced that I was going to go far with it. If you bust your ass trying to learn a valuable skill, it is undeniably satisfying once you start to figure it out. Yea, it’s a pain in the ass getting to that point, but it’s worth it. It takes a LOT of time and effort. There is no shortcut. That said, you should welcome a good challenge. It’s usually a lot more fun than being bored.
Music is also hard. I started playing cello when I was six. It took me at almost 10 years to not sound like shit (some might say I still do, but screw those guys). I almost quit more than a few times. But guess what? I sucked it up, and stuck with it. I am 23 now, and I can play the shit out of a cello. I put in my fair share of sweat and tears, but now I have something beautiful in my life that is both personally and financially rewarding. If I would have given up on cello, I would not be nearly as happy a person. Not to mention, I wouldn’t be able to impress all the pretty ladies (which also contributes to my happiness).
I’ve learned through music—and coding—that sometimes you need to convince yourself that it’s worth sticking with the hard things because they will pay off in the end. Now I’m a software engineer at an awesome company, as well as a musician in various musical projects around New Orleans. I couldn’t be happier. Well, I guess I could be a rockstar, but you can’t have it all…or can you?
We're building an AI-powered Product Operations Cloud, leveraging AI in almost every aspect of the software delivery lifecycle. Want to test drive it with us? Join the ProdOps party at ProdOps.ai.