Chances are you found this website through one of my Python articles. After all, in over 300+ articles, my most popular articles by far are all in my How to Python series. Don’t believe me? Check out my 2019 review. Naturally, over the years, I’ve tried to improve that series by adding YouTube videos, performance metrics, and even challenges. Well, now I’m releasing the How to Python series source code.
All code from the How to Python series can now be found in a GitHub repo. In particular, I’ve chosen to store all code snippets as Jupyter Notebooks, so you can run them in Google Colab. Head on over to the repo to check it out. Otherwise, keep reading for more details.
Table of Contents
Growing a Series
If you’ve been around, you know I started building up Python resources as soon as I picked up the language back in 2017. Since then, I’ve had a lot of fun expanding the series with articles while also freshening up the old content. For instance, each article used to feature just the code snippets. Now, many of them feature performance metrics and challenges.
To further grow the series, I started making YouTube videos that essentially repeat the content. In other words, each video features all the same code snippets with a bit of my own commentary. In a weird way, the articles function as my script.
At this point, the How to Python series features 21 articles and 8 YouTube videos. Now, I’m trying the continue this growth by introducing source code which you can clone, modify, and even share. In the next section, we’ll take a look at what that means.
Adding Source Code
Recently, I’ve been taking a grad course called Advanced Artificial Intelligence. In that course, I’ve been gaining some exposure to Jupyter Notebooks which allow you to embed Python code and text in a document. Even better, Google Colab offers an easy way to run that code in your browser. Naturally, I felt this would be a good fit for the series.
As a result, I created a GitHub repo called How to Python Code which includes a collection of Jupyter Notebooks, one for each article. At this moment, the project isn’t fully fleshed out, but there are a few notebooks already. For instance, you can check out the How to Write a Loop notebook here.
To make the collection easier to navigate, I’ve included a table in the README which links all of the articles in this collection as well as their respective notebooks if they exist. Each notebook link will take you directly to Google Colab where you can play around with each snippet.
My goal with this collection is to give newbies a chance to interact with the code snippet. Meanwhile, I wanted to give more experienced coders a chance to vet the code and even potentially provide updates or changes. Apparently, that’s something that some of you are interested in:
Plans for the Future
At this time, the code isn’t easy to edit unless you’re comfortable with Jupyter Notebooks. I’m currently interested in trying to find a way to add raw Python snippets to the repo, so you can edit them directly. I know there is a way to import local Python code into a Jupyter Notebook. I’m just not sure how to make that compatible with Google Colab.
Beyond that, I plan to maintain that repo as a way to catalog posts from the series. At the moment, the table displays publish dates and links, but it might be cool to include other information as well. If you have any ideas, let me know!
In the meantime, I’d love it if you stuck around to check out a few posts from the series. For instance, here are a few of my favorites:
Likewise, you can continue supporting the site by becoming a patron or even subscribing to my YouTube channel. If none that sounds interesting right now, at least consider hopping on my mailing list. Otherwise, thanks for stopping by!