def function(arg): return "value" function = decorator(function) # this passes the function to the decorator, and reassigns it to the functions As you may have seen ...
Python es completamente orientado a objetos y no tiene un "tipado estático". No necesitas declarar variables antes de usarlas ni declarar su tipo. Cada variable en Python es un objeto. Este tutorial ...