Python is a programming language with many terms that are important to understand. In this article, we will go over some of the common terms and their definitions in order to help you better learn Python.
Common Python terms
- Couroutine: it is a way to write asynchronous code in Python without using callbacks
- CPython: CPython is the most widely used implementation of the language. It’s written in C.
- Dictionary: A dictionary can be seen as an unordered set of key-value pairs with each value associated with just one key. The values are accessed by their keys, which means you need the right information for finding them out like doing math equations or going through your phone contacts list alphabetically from “A” to “Z.”
- Decorator: A Python decorator is a way to modify the behavior of functions without changing what the function does so it’s good for cases where you have existing code and want to extend its functionality but not change what it does in general.
- EAFP Programming: EAFP stands for ‘Easier to Ask for Forgiveness than Permission’ and EAFP Programming basically means that we want our code to be simple so it will make things easier on us and others.
- F-string: F-strings are a new type of string format in Python that is easier to use than the usual triple quoted strings because it automatically escapes quotes and special characters for us so all we have to do is enter our code into one line which saves time when coding.
- lamda: it is a keyword in Python, which is used to create anonymous functions
- list: it can be seen as an ordered collection of elements that we often need to iterate over.
- Machine Learning: Machine learning can be seen as an area within computer science where computers learn by themselves without being explicitly programmed or designed, they just need enough data input with examples on how decisions should work out. It’s important because there’s more different types of problems like basket filtering, natural language processing, image processing, etc., but not every machine has been created with these specific things mentioned like some other machines may only handle numbers instead of text.
- MRO: The MTRO stands for method resolution order which means this list contains all possible methods when looking up functions from objects – this same concept applies to classes too! This list includes class methods, instance methods, and built-in type subsets (e.g., dir()). Pythonic code represents a style of programming that is encouraged by the Python community. This coding includes things like having a single global namespace, following PEP-008 for imports, and not using exceptions to control flow.
- Qt for Python: The Qt framework provides an API which allows us to develop stand alone applications on Windows platforms as well as Linux or macOS desktop systems. It also has its own IDE called QT Creator (which can be downloaded free) with inbuilt code editor and designer tools. Qt for Python allows developers to make software with GUI with Python.
- set: set is also a type of data structure and are unordered collections with no duplicate values. So for example if you have the list [“a,” “b,” and “c] then it has three different values whereas a set would have only one value for that example.
- tuple: A tuple is an ordered sequence of elements just like lists but they are immutable so you can’t change the order or edit them as easily. Tuple’s also look prettier in print statements because they don’t need commas to separate each element.
- Variable: Variables are containers for data values such as integers, strings, booleans (true/false), etc., they can be modified during execution of each what remember not may you when on later read to easier code your make will this since beginning the at types explicit assign to practice good always.
- Zen of Python: The Zen of Python reads ‘there should be one–and preferably only one!–obvious way to do it.’ And when we look at this code through our highlighter there are many ways but if you go back and read through each line the first time, you will notice that the way with (a) fewest number of lines is also the most Pythonic!