class A:
    def __init__(self, txt: str):
        self.w: G = None
        self.r: G = None
        self.y: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: H = None
        self.r: D = None
        self.z: C = None
        self.y: C = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.z: F = None
        self.o: G = None
        self.q: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: B = None
        self.x: C = None
        self.t: A = None
        self.z: A = None
        self.p: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: C = None
        self.w: G = None
        self.y: D = None
        self.z: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: H = None
        self.r: D = None
        self.z: C = None
        self.y: C = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.t: D = None
        self.z: F = None
        self.o: G = None
        self.q: F = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.w: B = None
        self.x: C = None
        self.t: A = None
        self.z: A = None
        self.p: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: C = None
        self.w: G = None
        self.y: D = None
        self.z: E = None
        self.txt = txt

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

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