class A:
    def __init__(self, txt: str):
        self.x: C = None
        self.q: F = None
        self.y: G = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: H = None
        self.t: H = None
        self.y: B = None
        self.v: J = None
        self.s: J = None
        self.r: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.y: I = None
        self.v: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.v: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.o: C = None
        self.t: J = None
        self.p: C = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.s: G = None
        self.r: C = None
        self.y: G = None
        self.t: A = None
        self.z: A = None
        self.u: D = None
        self.o: G = None
        self.txt = txt

a = A("a")
n = B("n")
f = C("f")
l = D("l")
j = E("j")
d = F("d")
e = G("e")
g = H("g")
h = I("h")
c = J("c")

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

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

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.u: H = None
        self.t: H = None
        self.y: B = None
        self.v: J = None
        self.s: J = None
        self.r: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.y: I = None
        self.v: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: F = None
        self.v: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: G = None
        self.o: C = None
        self.t: J = None
        self.p: C = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.s: G = None
        self.r: C = None
        self.y: G = None
        self.t: A = None
        self.z: A = None
        self.u: D = None
        self.o: G = None
        self.txt = txt

a = A("a")
n = B("n")
f = C("f")
l = D("l")
j = E("j")
d = F("d")
e = G("e")
g = H("g")
h = I("h")
c = J("c")

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