Skip to content

Instantly share code, notes, and snippets.

@pallavg55
Last active August 18, 2017 11:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save pallavg55/ef33243739d86ef224369a7090b5099d to your computer and use it in GitHub Desktop.
Save pallavg55/ef33243739d86ef224369a7090b5099d to your computer and use it in GitHub Desktop.
class Animal:
"""Animal class"""
animal = 'dog'
@classmethod
def change_animal(cls, new_animal):
"""Change animal for class"""
return cls.animal = new_animal
def print_animal(self):
"""Return animal"""
return self.animal
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment