class A:
    def __init__(self, txt: str):
        self.o: D = None
        self.y: I = None
        self.v: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: G = None
        self.w: E = None
        self.t: G = None
        self.q: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.w: B = None
        self.s: G = None
        self.p: A = None
        self.x: E = None
        self.q: B = None
        self.u: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: J = None
        self.q: J = None
        self.x: C = None
        self.t: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.r: C = None
        self.u: E = None
        self.z: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: I = None
        self.p: I = None
        self.x: D = None
        self.q: B = None
        self.v: F = None
        self.s: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: G = None
        self.w: E = None
        self.t: G = None
        self.q: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: B = None
        self.w: B = None
        self.s: G = None
        self.p: A = None
        self.x: E = None
        self.q: B = None
        self.u: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.y: J = None
        self.q: J = None
        self.x: C = None
        self.t: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.r: C = None
        self.u: E = None
        self.z: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: I = None
        self.p: I = None
        self.x: D = None
        self.q: B = None
        self.v: F = None
        self.s: A = None
        self.txt = txt

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

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