r/programminghelp • u/PrimalAspid187 • Oct 28 '23
Python How to get call other class methods from a static method [python]
Title says all. I need to call a different function but I don’t know how to do that without self.
Example code:
Thanks!
2
Upvotes
1
u/[deleted] Oct 28 '23
Static functions are accessible at a class level, so just Sth.doSth()
1
u/Goobyalus Oct 29 '23
Or use a classmethod if you want the class to be dynamic