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

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.z: A = None
        self.y: C = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.r: E = None
        self.w: B = None
        self.y: H = None
        self.p: E = None
        self.x: D = None
        self.s: B = None
        self.o: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: J = None
        self.q: J = None
        self.w: G = None
        self.t: B = None
        self.o: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: I = None
        self.w: I = None
        self.x: H = None
        self.s: G = None
        self.p: J = None
        self.u: J = None
        self.q: I = None
        self.z: I = None
        self.v: D = None
        self.t: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: J = None
        self.p: B = None
        self.o: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: D = None
        self.x: J = None
        self.t: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.s: D = None
        self.q: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: G = None
        self.o: B = None
        self.u: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.z: A = None
        self.y: C = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: D = None
        self.r: E = None
        self.w: B = None
        self.y: H = None
        self.p: E = None
        self.x: D = None
        self.s: B = None
        self.o: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: J = None
        self.q: J = None
        self.w: G = None
        self.t: B = None
        self.o: G = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: I = None
        self.w: I = None
        self.x: H = None
        self.s: G = None
        self.p: J = None
        self.u: J = None
        self.q: I = None
        self.z: I = None
        self.v: D = None
        self.t: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: J = None
        self.p: B = None
        self.o: I = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: D = None
        self.x: J = None
        self.t: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: A = None
        self.s: D = None
        self.q: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.q: G = None
        self.o: B = None
        self.u: A = None
        self.txt = txt

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

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