Skip to content

Instantly share code, notes, and snippets.

@NMZivkovic
Created March 3, 2019 11:49
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 NMZivkovic/ecf8bbc0bb7a16b736c8c959e8f7fa2e to your computer and use it in GitHub Desktop.
Save NMZivkovic/ecf8bbc0bb7a16b736c8c959e8f7fa2e to your computer and use it in GitHub Desktop.
from rick import Rick
class Citadel(object):
def __init__(self):
self.__residents__ = []
def get_all_residents(self):
return self.__residents__
def add_resident(self, resident):
self.__residents__.append(resident)
def picle_ricks_with_morties(self):
for resident in self.__residents__:
if isinstance(resident, Rick):
if resident.morty: resident.is_pickle = True
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment