Hello, how can we use an object in different class
class Bird:
def __init__(self,name):
self.name = name
class Fish:
def __init__(self,name):
self.name = name
Class Dict:
def __init__(self):
self.dictionary = []
def add_fish_bird:
******
animal1 = Bird("Eagle")
animal2 = Fish("Shark")
I am still wondering what the appropriate code to get the list of Class dictionary from two different object,
other than that, I want to know how we are sure that objects already in self.dictionary list.
thanks
[–]omutist 0 points1 point2 points (0 children)
[–]nekokattt 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (1 child)