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

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

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

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.q: C = None
        self.v: B = None
        self.p: G = None
        self.t: G = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: C = None
        self.y: G = None
        self.o: E = None
        self.w: E = None
        self.z: C = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.q: C = None
        self.v: B = None
        self.p: G = None
        self.t: G = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.p: A = None
        self.x: C = None
        self.y: G = None
        self.o: E = None
        self.w: E = None
        self.z: C = None
        self.txt = txt

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

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