class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: H = None
        self.x: A = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: F = None
        self.w: E = None
        self.v: A = None
        self.x: C = None
        self.t: C = None
        self.s: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.q: B = None
        self.o: B = None
        self.p: D = None
        self.v: D = None
        self.u: D = None
        self.t: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: H = None
        self.x: A = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: F = None
        self.w: E = None
        self.v: A = None
        self.x: C = None
        self.t: C = None
        self.s: A = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.y: F = None
        self.q: B = None
        self.o: B = None
        self.p: D = None
        self.v: D = None
        self.u: D = None
        self.t: F = None
        self.txt = txt

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

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