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

class B:
    def __init__(self, txt: str):
        self.w: A = None
        self.y: C = None
        self.u: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: B = None
        self.z: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.t: B = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.s: D = None
        self.w: B = None
        self.t: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: E = None
        self.w: F = None
        self.r: B = None
        self.o: B = None
        self.y: E = None
        self.v: F = None
        self.txt = txt

g = A("g")
a = B("a")
n = C("n")
h = D("h")
i = E("i")
k = F("k")
m = G("m")
l = H("l")
d = C("d")
c = G("c")

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

class B:
    def __init__(self, txt: str):
        self.w: A = None
        self.y: C = None
        self.u: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: D = None
        self.s: B = None
        self.z: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.t: B = None
        self.y: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.s: D = None
        self.w: B = None
        self.t: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.p: E = None
        self.w: F = None
        self.r: B = None
        self.o: B = None
        self.y: E = None
        self.v: F = None
        self.txt = txt

g = A("g")
a = B("a")
n = C("n")
h = D("h")
i = E("i")
k = F("k")
m = G("m")
l = H("l")
d = C("d")
c = G("c")

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