class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.w: D = None
        self.p: I = None
        self.r: I = None
        self.o: G = None
        self.t: D = None
        self.z: E = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.w: D = None
        self.t: E = None
        self.u: I = None
        self.z: E = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: G = None
        self.q: A = None
        self.o: I = None
        self.w: I = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.p: F = None
        self.t: D = None
        self.y: G = None
        self.x: A = None
        self.o: A = None
        self.s: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.s: I = None
        self.z: D = None
        self.u: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.x: C = None
        self.v: B = None
        self.o: I = None
        self.y: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.q: F = None
        self.r: D = None
        self.y: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.q: C = None
        self.y: E = None
        self.p: A = None
        self.r: C = None
        self.u: B = None
        self.txt = txt

c = A("c")
j = B("j")
d = C("d")
g = D("g")
b = E("b")
l = F("l")
i = G("i")
a = H("a")
e = I("e")

c.s = j
c.w = g
c.t = g
c.p = e
c.r = e
c.o = i
c.z = b
c.y = l
c.v = l
j.s = d
j.r = d
d.x = c
d.w = g
d.t = b
d.z = b
d.u = e
d.y = l
g.v = i
g.q = c
g.z = c
g.o = e
g.w = e
b.r = j
b.p = l
b.t = g
b.y = i
b.x = c
b.o = c
b.s = c
l.x = a
l.s = e
l.z = g
l.u = j
i.s = g
i.x = d
i.v = j
i.o = e
i.y = e
a.s = d
a.q = l
a.y = l
a.r = g
e.x = b
e.y = b
e.v = j
e.u = j
e.q = d
e.r = d
e.p = c
assert i.x.y.z.txt == "
class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.w: D = None
        self.p: I = None
        self.r: I = None
        self.o: G = None
        self.t: D = None
        self.z: E = None
        self.y: F = None
        self.v: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: A = None
        self.w: D = None
        self.t: E = None
        self.u: I = None
        self.z: E = None
        self.y: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: G = None
        self.q: A = None
        self.o: I = None
        self.w: I = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.p: F = None
        self.t: D = None
        self.y: G = None
        self.x: A = None
        self.o: A = None
        self.s: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.s: I = None
        self.z: D = None
        self.u: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.x: C = None
        self.v: B = None
        self.o: I = None
        self.y: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.q: F = None
        self.r: D = None
        self.y: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: E = None
        self.v: B = None
        self.q: C = None
        self.y: E = None
        self.p: A = None
        self.r: C = None
        self.u: B = None
        self.txt = txt

c = A("c")
j = B("j")
d = C("d")
g = D("g")
b = E("b")
l = F("l")
i = G("i")
a = H("a")
e = I("e")

c.s = j
c.w = g
c.t = g
c.p = e
c.r = e
c.o = i
c.z = b
c.y = l
c.v = l
j.s = d
j.r = d
d.x = c
d.w = g
d.t = b
d.z = b
d.u = e
d.y = l
g.v = i
g.q = c
g.z = c
g.o = e
g.w = e
b.r = j
b.p = l
b.t = g
b.y = i
b.x = c
b.o = c
b.s = c
l.x = a
l.s = e
l.z = g
l.u = j
i.s = g
i.x = d
i.v = j
i.o = e
i.y = e
a.s = d
a.q = l
a.y = l
a.r = g
e.x = b
e.y = b
e.v = j
e.u = j
e.q = d
e.r = d
e.p = c
assert i.x.y.z.txt == "g"