I want to write a general code that take the number of stages of a turbine and then calculate different features of every blade. I want to use class in this code but there is something wrong with my code and I simplified the problem in code below:
class aa():
x1 =1
y1=2
z1=3
class bb():
x2=aa()
y2=aa()
class cc:
x3=[]
y3=[]
ee=cc()
for i in range(0, 3):
ee.x3.append(bb())
ee.y3.append(bb())
print(ee.x3[0]) # prints 12 !!
ee.x3[0].x2.x1=7
ee.y3[0].x2.x1=12
print(ee.x3[0].x2.x1) # prints 12 instead of 7 !!
thanks