class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.q: I = None
        self.p: F = None
        self.t: G = None
        self.o: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: I = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.z: F = None
        self.w: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: F = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: B = None
        self.v: F = None
        self.p: E = None
        self.z: G = None
        self.q: B = None
        self.u: C = None
        self.y: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: H = None
        self.s: D = None
        self.u: G = None
        self.r: D = None
        self.t: E = None
        self.v: G = None
        self.y: H = None
        self.w: H = None
        self.txt = txt

b = A("b")
m = B("m")
k = C("k")
e = D("e")
c = E("c")
i = F("i")
h = G("h")
g = H("g")
a = I("a")

b.s = k
b.q = a
b.p = i
b.t = h
b.o = g
m.w = c
m.z = c
m.r = a
k.z = h
e.o = k
e.z = i
e.w = g
c.y = i
i.w = m
i.p = b
i.x = e
i.t = h
i.s = c
i.y = a
h.v = m
h.o = k
h.y = k
h.q = b
h.x = a
h.t = a
h.r = c
h.p = c
h.u = e
g.r = i
g.v = i
g.y = i
g.x = m
g.q = m
g.p = c
g.z = h
g.u = k
a.p = g
a.y = g
a.w = g
a.s = e
a.r = e
a.u = h
a.v = h
a.t = c
assert k.z.r.y.txt == "
class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.q: I = None
        self.p: F = None
        self.t: G = None
        self.o: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.r: I = None
        self.z: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.z: F = None
        self.w: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: F = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.r: F = None
        self.x: B = None
        self.v: F = None
        self.p: E = None
        self.z: G = None
        self.q: B = None
        self.u: C = None
        self.y: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: H = None
        self.s: D = None
        self.u: G = None
        self.r: D = None
        self.t: E = None
        self.v: G = None
        self.y: H = None
        self.w: H = None
        self.txt = txt

b = A("b")
m = B("m")
k = C("k")
e = D("e")
c = E("c")
i = F("i")
h = G("h")
g = H("g")
a = I("a")

b.s = k
b.q = a
b.p = i
b.t = h
b.o = g
m.w = c
m.z = c
m.r = a
k.z = h
e.o = k
e.z = i
e.w = g
c.y = i
i.w = m
i.p = b
i.x = e
i.t = h
i.s = c
i.y = a
h.v = m
h.o = k
h.y = k
h.q = b
h.x = a
h.t = a
h.r = c
h.p = c
h.u = e
g.r = i
g.v = i
g.y = i
g.x = m
g.q = m
g.p = c
g.z = h
g.u = k
a.p = g
a.y = g
a.w = g
a.s = e
a.r = e
a.u = h
a.v = h
a.t = c
assert k.z.r.y.txt == "i"