Defining High-Quality Code
00:00 High-quality code has some characteristics that set it apart from low-quality code. You saw an example earlier with two blocks of code that calculate the area of a rectangle.
00:11 One was high-quality, the other one was low-quality. One takeaway here was that they both actually worked. Even the lower-quality code got the job done. So if you were to put low-quality code into words, you could say that low-quality code has the minimal required characteristics to be functional, and it doesn’t contain critical errors.
00:35 What about the characteristics of high-quality code? In addition to being functional, high-quality code is readable, meaning it uses things like descriptive variable names and docstrings to make it straightforward for anyone to understand what the code is supposed to do.
00:53 High-quality code is efficient, meaning it uses appropriate data structures for the problem at hand, and it’s reusable, meaning you can reuse your functions or other variables throughout your codebase without having to repeat yourself.
01:08 These characteristics, meaning functionality, readability, efficiency, reusability, are what you’ll focus on in this video course. But there are others. You can check out this Real Python tutorial called Python Code Quality: Best Practices and Tools to learn more.
01:26 In the next lessons, you’ll zoom in on each of the high-quality code traits that you just encountered more in depth, and you’ll also learn how to implement them practically.
Become a Member to join the conversation.
