In this Python tutorial for beginners I show how to create a class and derived a subclass from it, which is in OOP called inheritance.
After that I create an instance of the derived class (Rectangle) and I also added an __str__ method to have a string reperesentation of the class with that we are able to print out the data of the class in a human-readable form.
See my social profiles here
G+: [ Ссылка ]
Twitter: [ Ссылка ]
Facebook: [ Ссылка ]
Patreon: [ Ссылка ]
Production Music courtesy of Epidemic Sound: [ Ссылка ]
#python
#pythontutorial
#oop
![](https://s2.save4k.ru/pic/YuQdF4Bm9nE/maxresdefault.jpg)