class A:
    def __init__(self, txt: str):
        self.x: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.x: E = None
        self.v: H = None
        self.t: D = None
        self.w: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.r: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.s: A = None
        self.q: F = None
        self.y: C = None
        self.p: E = None
        self.r: C = None
        self.u: C = None
        self.x: C = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.x: E = None
        self.v: H = None
        self.t: D = None
        self.w: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.r: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.o: B = None
        self.s: A = None
        self.q: F = None
        self.y: C = None
        self.p: E = None
        self.r: C = None
        self.u: C = None
        self.x: C = None
        self.txt = txt

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

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

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