Choosing an Advent of Code Language
Today is the first day of “Advent of Code”. You’ve probably been hearing a lot about the different programming languages that people love coding in. The Advent of Code is a good time to try out a new language, but how do you decide? Here’s are some thoughts.
Aesthetics is an important part of code. But beauty is in the eye of the beholder, so two people will likely have different ideas about what they like. To get a quick look at the syntax of your potential language, perform a web search for “fizzbuzz in {language}” where {language} is the name of your candidate programming language. For example, “fizzbuzz in go” or “fizzbuzz in PHP”. Why is this a good strategy? The fizzbuzz exercise contains the fundamentals aspects of structured programming – functions, conditionals, and loops. Because it’s a well-defined exercise, you can easily evaluate the form of the code, since you already know what it’s supposed to do. This is enough to determine if you want to look deeper into a language, or if you want to move on to the next one.
I’ve been hearing from some people new to PHP that they weren’t sure if they were going to like it (because of internet chatter), but the more they learned about it, the more they liked PHP. So evaluate a language for yourself, and not what someone else thinks. They have their own bias, which may not align with your interests.
If you’ve been considering learning a language because it would look good on your resume, this type of contest is a good way to evaluate a language. If you don’t enjoy writing in a language for an fun contest like Advent of Code, it’s better to find out early before you invest too much time. If a language doesn’t click with you, that’s fine. Try another. Good luck in your coding journey.