Operators
Let's talk about operators. An operator is something between 2 variables / values and does something to them.
For example, the addition operator:
Python supports many maths operators:
Now the cool thing, operators don't just work on numbers. They work on strings too. And lists. And dictionaries.
Well, operators work on any data structure that has implemented a magic method for them.
Magic methods are rather wild, but require prequesite knolwedge of object orientated programming fiest.
Last updated