3 ms·
> Static method? @staticmethod > Static variable? declare it outside of your methods but inside your class Sounds like you're still thinking in Java :).
by lmm 8y ago
> Static method? @staticmethod
> Static variable? declare it outside of your methods but inside your class
Sounds like you're still thinking in Java :). A static method is rarely what you want (and if you do you can put it on the class like for variables); functions are first-class so you can just put them in your module.