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

class B:
    def __init__(self, txt: str):
        self.o: H = None
        self.z: A = None
        self.p: H = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: D = None
        self.u: C = None
        self.o: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: H = None
        self.z: A = None
        self.p: H = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: D = None
        self.u: C = None
        self.o: D = None
        self.txt = txt

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

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