Designing algorithms
When designing algorithms, order matters. There are hierarchies that we have to take into account when working with programming languages and that includes Python. Think about this as the order of operations in mathematics. If you recall, we use the mnemonic PEMDAS to remember the order of operations in mathematics. PEMDAS stands for Parentheses, Exponents, Multiplication/Division, and Addition/Subtraction.
I write Multiplication/Division together like this because multiplication and division hold the same weight. That is, multiplication does not necessarily need to happen before division. If I have a division first and then a multiplication from left to right, the division happens first. The same is true for addition and subtraction. Neither has more weight than the other, so we perform them in order of appearance from left to right.
Keep in mind that these are just some of the operations we use in mathematics. They are frequently called the basic arithmetic...