class A:
    def __init__(self, txt: str):
        self.w: B = None
        self.v: H = None
        self.t: F = None
        self.u: G = None
        self.z: D = None
        self.y: F = None
        self.s: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.s: D = None
        self.t: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.o: G = None
        self.r: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.y: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.z: G = None
        self.u: C = None
        self.v: D = None
        self.r: B = None
        self.o: E = None
        self.y: C = None
        self.p: B = None
        self.txt = txt

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

d.w = b
d.v = f
d.t = h
d.y = h
d.s = h
d.u = e
d.z = n
b.u = m
m.w = b
m.t = b
m.s = n
n.u = f
n.o = e
n.r = k
k.r = e
h.p = k
h.y = k
h.x = f
e.s = n
e.w = k
f.z = e
f.u = m
f.y = m
f.v = n
f.r = b
f.p = b
f.o = k
assert m.t.u.t.u.s.u.txt == "
class A:
    def __init__(self, txt: str):
        self.w: B = None
        self.v: H = None
        self.t: F = None
        self.u: G = None
        self.z: D = None
        self.y: F = None
        self.s: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.w: B = None
        self.s: D = None
        self.t: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: H = None
        self.o: G = None
        self.r: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.x: H = None
        self.y: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.z: G = None
        self.u: C = None
        self.v: D = None
        self.r: B = None
        self.o: E = None
        self.y: C = None
        self.p: B = None
        self.txt = txt

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

d.w = b
d.v = f
d.t = h
d.y = h
d.s = h
d.u = e
d.z = n
b.u = m
m.w = b
m.t = b
m.s = n
n.u = f
n.o = e
n.r = k
k.r = e
h.p = k
h.y = k
h.x = f
e.s = n
e.w = k
f.z = e
f.u = m
f.y = m
f.v = n
f.r = b
f.p = b
f.o = k
assert m.t.u.t.u.s.u.txt == "f"