class A:
    def __init__(self, txt: str):
        self.q: C = None
        self.w: C = None
        self.t: C = None
        self.x: F = None
        self.u: H = None
        self.v: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: F = None
        self.v: G = None
        self.w: A = None
        self.t: H = None
        self.x: A = None
        self.s: E = None
        self.z: H = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.w: B = None
        self.v: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: F = None
        self.x: H = None
        self.q: A = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: F = None
        self.v: G = None
        self.w: A = None
        self.t: H = None
        self.x: A = None
        self.s: E = None
        self.z: H = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.w: B = None
        self.v: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: F = None
        self.x: H = None
        self.q: A = None
        self.txt = txt

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

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

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