class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.y: H = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.t: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: F = None
        self.s: F = None
        self.w: F = None
        self.u: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: B = None
        self.u: I = None
        self.s: H = None
        self.r: A = None
        self.v: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: D = None
        self.y: I = None
        self.w: E = None
        self.x: F = None
        self.r: B = None
        self.txt = txt

d = A("d")
m = B("m")
j = C("j")
k = D("k")
h = E("h")
n = F("n")
f = G("f")
l = H("l")
i = I("i")
g = J("g")

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

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

class C:
    def __init__(self, txt: str):
        self.v: B = None
        self.t: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: F = None
        self.s: F = None
        self.w: F = None
        self.u: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: B = None
        self.u: I = None
        self.s: H = None
        self.r: A = None
        self.v: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.r: B = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.o: D = None
        self.y: I = None
        self.w: E = None
        self.x: F = None
        self.r: B = None
        self.txt = txt

d = A("d")
m = B("m")
j = C("j")
k = D("k")
h = E("h")
n = F("n")
f = G("f")
l = H("l")
i = I("i")
g = J("g")

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