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

class B:
    def __init__(self, txt: str):
        self.y: H = None
        self.z: F = None
        self.s: F = None
        self.p: F = None
        self.o: G = None
        self.u: A = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.t: E = None
        self.o: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: D = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: G = None
        self.t: D = None
        self.q: G = None
        self.s: E = None
        self.u: A = None
        self.o: A = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

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

f = A("f")
a = B("a")
n = C("n")
l = D("l")
i = E("i")
k = F("k")
m = G("m")
e = H("e")
g = E("g")

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

class B:
    def __init__(self, txt: str):
        self.y: H = None
        self.z: F = None
        self.s: F = None
        self.p: F = None
        self.o: G = None
        self.u: A = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.t: E = None
        self.o: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: D = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.w: G = None
        self.t: D = None
        self.q: G = None
        self.s: E = None
        self.u: A = None
        self.o: A = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

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

f = A("f")
a = B("a")
n = C("n")
l = D("l")
i = E("i")
k = F("k")
m = G("m")
e = H("e")
g = E("g")

f.t = m
f.o = g
f.u = a
f.s = e
a.y = e
a.z = k
a.s = k
a.p = k
a.o = m
a.u = f
a.w = f
n.t = i
n.o = e
l.q = m
l.v = e
i.w = l
i.o = m
k.r = e
k.w = m
k.q = m
k.t = l
k.v = l
k.s = i
k.u = f
k.o = f
m.v = e
e.z = f
e.t = m
e.p = k
e.x = l
g.w = l
g.o = m
assert a.p.w.v.x.q.v.t.txt == "m"