class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: E = None
        self.o: G = None
        self.y: C = None
        self.z: F = None
        self.t: E = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

e.u = f
e.o = g
d.q = m
n.u = f
n.y = f
n.x = h
n.o = m
n.z = k
n.t = i
g.s = k
g.w = d
g.q = i
i.z = f
i.q = f
i.s = h
i.w = h
i.u = k
i.y = g
i.t = m
k.q = m
m.u = k
f.u = n
f.y = n
f.x = i
f.t = i
f.o = m
f.z = k
h.z = n
h.s = i
h.w = i
h.q = f
h.u = k
h.y = g
h.t = m
assert e.u.y.u.txt == "
class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.u: C = None
        self.x: E = None
        self.o: G = None
        self.y: C = None
        self.z: F = None
        self.t: E = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

e.u = f
e.o = g
d.q = m
n.u = f
n.y = f
n.x = h
n.o = m
n.z = k
n.t = i
g.s = k
g.w = d
g.q = i
i.z = f
i.q = f
i.s = h
i.w = h
i.u = k
i.y = g
i.t = m
k.q = m
m.u = k
f.u = n
f.y = n
f.x = i
f.t = i
f.o = m
f.z = k
h.z = n
h.s = i
h.w = i
h.q = f
h.u = k
h.y = g
h.t = m
assert e.u.y.u.txt == "f"