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

class B:
    def __init__(self, txt: str):
        self.o: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: F = None
        self.w: B = None
        self.z: A = None
        self.q: C = None
        self.r: H = None
        self.p: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.r: F = None
        self.x: E = None
        self.t: A = None
        self.o: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: A = None
        self.v: A = None
        self.r: B = None
        self.t: D = None
        self.q: A = None
        self.p: G = None
        self.u: D = None
        self.w: G = None
        self.txt = txt

a = A("a")
f = B("f")
l = C("l")
i = D("i")
b = E("b")
c = F("c")
d = G("d")
k = H("k")

a.z = i
a.u = k
a.q = l
f.o = b
l.t = f
l.q = c
l.u = c
i.x = d
i.o = c
i.w = f
i.z = a
i.q = l
i.p = l
i.r = k
b.q = d
b.y = a
b.s = a
b.p = k
b.t = i
b.w = f
b.x = l
b.u = c
c.v = d
c.t = a
c.w = a
c.y = i
d.z = k
d.s = f
d.r = c
d.x = b
d.t = a
d.o = i
k.s = a
k.v = a
k.q = a
k.r = f
k.t = i
k.u = i
k.p = d
k.w = d
assert c.y.q.t.o.w.o.txt == "
class A:
    def __init__(self, txt: str):
        self.z: D = None
        self.u: H = None
        self.q: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: E = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: F = None
        self.w: B = None
        self.z: A = None
        self.q: C = None
        self.r: H = None
        self.p: C = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.r: F = None
        self.x: E = None
        self.t: A = None
        self.o: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: A = None
        self.v: A = None
        self.r: B = None
        self.t: D = None
        self.q: A = None
        self.p: G = None
        self.u: D = None
        self.w: G = None
        self.txt = txt

a = A("a")
f = B("f")
l = C("l")
i = D("i")
b = E("b")
c = F("c")
d = G("d")
k = H("k")

a.z = i
a.u = k
a.q = l
f.o = b
l.t = f
l.q = c
l.u = c
i.x = d
i.o = c
i.w = f
i.z = a
i.q = l
i.p = l
i.r = k
b.q = d
b.y = a
b.s = a
b.p = k
b.t = i
b.w = f
b.x = l
b.u = c
c.v = d
c.t = a
c.w = a
c.y = i
d.z = k
d.s = f
d.r = c
d.x = b
d.t = a
d.o = i
k.s = a
k.v = a
k.q = a
k.r = f
k.t = i
k.u = i
k.p = d
k.w = d
assert c.y.q.t.o.w.o.txt == "b"