class A:
    def __init__(self, txt: str):
        self.w: G = None
        self.z: E = None
        self.x: H = None
        self.u: G = None
        self.o: H = None
        self.t: E = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: H = None
        self.r: H = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: H = None
        self.u: D = None
        self.s: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: B = None
        self.s: A = None
        self.t: F = None
        self.y: F = None
        self.v: B = None
        self.u: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: H = None
        self.y: H = None
        self.s: A = None
        self.z: A = None
        self.r: H = None
        self.u: I = None
        self.v: H = None
        self.p: C = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: H = None
        self.r: H = None
        self.x: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: H = None
        self.u: D = None
        self.s: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.p: B = None
        self.s: A = None
        self.t: F = None
        self.y: F = None
        self.v: B = None
        self.u: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: H = None
        self.y: H = None
        self.s: A = None
        self.z: A = None
        self.r: H = None
        self.u: I = None
        self.v: H = None
        self.p: C = None
        self.txt = txt

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

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