Skip to content

Instantly share code, notes, and snippets.

@alejandrobernardis
Created September 15, 2012 23:34
Show Gist options
  • Select an option

  • Save alejandrobernardis/3730351 to your computer and use it in GitHub Desktop.

Select an option

Save alejandrobernardis/3730351 to your computer and use it in GitHub Desktop.
por estas cosas amo a python!
class A(object):
@staticmethod
def sm(cls, p1=None, p2=None):
print cls, p1, p2
@classmethod
def cm(cls, p1=None, p2=None):
print cls, p1, p2
class B(A):
pass
B.mm(B, 1, 2)
B.cm(1, 2)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment