class A:
    def __init__(self, txt: str):
        self.x: B = None
        self.s: C = None
        self.v: C = None
        self.r: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.s: I = None
        self.u: E = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.z: G = None
        self.y: A = None
        self.o: A = None
        self.v: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.u: H = None
        self.r: H = None
        self.w: E = None
        self.y: C = None
        self.t: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: B = None
        self.o: I = None
        self.x: H = None
        self.q: H = None
        self.w: E = None
        self.p: E = None
        self.txt = txt

a = A("a")
k = B("k")
b = C("b")
l = D("l")
m = E("m")
h = F("h")
e = G("e")
i = H("i")
c = I("c")
j = I("j")

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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.s: I = None
        self.u: E = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.z: G = None
        self.y: A = None
        self.o: A = None
        self.v: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: C = None
        self.u: H = None
        self.r: H = None
        self.w: E = None
        self.y: C = None
        self.t: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.u: B = None
        self.o: I = None
        self.x: H = None
        self.q: H = None
        self.w: E = None
        self.p: E = None
        self.txt = txt

a = A("a")
k = B("k")
b = C("b")
l = D("l")
m = E("m")
h = F("h")
e = G("e")
i = H("i")
c = I("c")
j = I("j")

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