A challenge in software development is to keep things simple 🤯 For your code to not grow overly complex over time 😱 Simple is better than complex.Complex is better than complicated. Zen of Python 🐍 Simplicity in your code means fewer possibilities for bugs to hide and easier debugging when they do arise 📈 It… Continue reading Make Each Line Count, Keeping Things Simple in Python
Articles on pythonic
Tips for clean code in Python
By Bob Belderbos on 8 November 2022
In this article I will give you 10 tips for cleaner code. Hope this helps improve your Python code. 1. Smaller units. Break long functions (methods) into multiple smaller ones that do one thing (SRP or “Single-responsibility principle”). This will make your code more modular and easier to test. For example, a function that parses… Continue reading Tips for clean code in Python
4 Common Mistakes When Learning Python and Programming
By Bob Belderbos on 19 March 2020
How are you progressing with your Python? What could be holding you back? I gave it some thought and identified 4 issues we commonly see that hold people back from becoming a proficient Pythonista and programmer.
A Python Orientation – How to Get Started
By Andrew Knight on 17 August 2018
Python is a wonderful language for both beginners and expert programmers, but getting started can be daunting. Which version should I use? Which editors are best? What do you mean there are different implementations and environments? Here’s a guide to help navigate these big FAQs.
Code Challenge 30 – The Art of Refactoring: Improve Your Code
By PyBites Team on 1 August 2017
Hi Pythonistas, a new week, a new ‘bite’ of Python coding. Wow challenge 30 already! This week we let you hone your refactoring skills. Learn, code, PR submit (don’t be shy) and above all have fun!
Comparing Lists with Difflib
By Julian Sequeira on 8 March 2017
Learn to compare blocks of text with the difflib module.
Pythonic String Formatting
By Julian Sequeira on 2 March 2017
The formatting of strings has been a hot topic in Python and something that I struggled with at the beginning. It’s quite interesting to see how it’s evolved over time to be what it is today!
5 tips to speed up your Python code
By Bob Belderbos on 21 February 2017
In this post I will give you 5 tips to speed up your code.
Python Tricks book review
By Bob Belderbos on 31 January 2017
A review of Dan Bader’s Python tricks book.
Python’s data model by example
By Bob Belderbos on 25 January 2017
After last post on OOP a logical follow-up is Python’s data model. We use the great Fluent Python book to code up an example of our own, showing the powerful way you can leverage this data model. You can download the notebook here.