What is the correct way to access a class composite inside one of its components, if that's even advisable?

后端 未结 0 1559
遥遥无期
遥遥无期 2021-01-19 01:24

Suppose I have these two classes:

class Branch():
    def __init__(self, id, leaves):
        self.id = id
        self.leaves = leaves
    
class Leaf():
            


        
相关标签:
回答
  • 消灭零回复
提交回复
热议问题