class A:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: D = None
        self.p: F = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.w: E = None
        self.z: E = None
        self.u: B = None
        self.y: B = None
        self.q: A = None
        self.x: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: C = None
        self.q: A = None
        self.txt = txt

m = A("m")
g = B("g")
e = C("e")
d = D("d")
l = E("l")
k = F("k")
n = G("n")
c = E("c")
f = E("f")

m.o = f
m.s = d
m.p = k
g.z = f
g.u = e
g.q = d
e.r = g
d.s = f
d.z = f
d.q = k
l.z = k
l.r = d
l.y = n
l.v = m
k.w = l
k.z = c
k.u = g
k.y = g
k.q = m
k.x = n
n.r = e
n.q = m
c.z = k
c.r = d
c.y = n
c.v = m
f.z = k
f.r = d
f.y = n
f.v = m
assert l.y.q.p.u.u.txt == "
class A:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: D = None
        self.p: F = None
        self.txt = txt

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.w: E = None
        self.z: E = None
        self.u: B = None
        self.y: B = None
        self.q: A = None
        self.x: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: C = None
        self.q: A = None
        self.txt = txt

m = A("m")
g = B("g")
e = C("e")
d = D("d")
l = E("l")
k = F("k")
n = G("n")
c = E("c")
f = E("f")

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