class A:
    def __init__(self, txt: str):
        self.o: C = None
        self.t: D = None
        self.x: G = None
        self.r: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.x: D = None
        self.q: C = None
        self.p: F = None
        self.w: F = None
        self.v: G = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: B = None
        self.o: G = None
        self.p: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.w: D = None
        self.o: E = None
        self.x: A = None
        self.v: F = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.y: E = None
        self.x: D = None
        self.q: C = None
        self.p: F = None
        self.w: F = None
        self.v: G = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: B = None
        self.o: G = None
        self.p: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: E = None
        self.w: D = None
        self.o: E = None
        self.x: A = None
        self.v: F = None
        self.txt = txt

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

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

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

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

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