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

class B:
    def __init__(self, txt: str):
        self.u: H = None
        self.t: A = None
        self.o: G = None
        self.v: F = None
        self.x: G = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: I = None
        self.q: G = None
        self.w: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: A = None
        self.w: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.q: J = None
        self.p: A = None
        self.r: A = None
        self.v: C = None
        self.z: D = None
        self.u: J = None
        self.y: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.v: B = None
        self.o: E = None
        self.u: H = None
        self.p: J = None
        self.t: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: C = None
        self.v: A = None
        self.o: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: I = None
        self.r: C = None
        self.u: B = None
        self.s: G = None
        self.q: E = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.u: H = None
        self.t: A = None
        self.o: G = None
        self.v: F = None
        self.x: G = None
        self.z: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: I = None
        self.q: G = None
        self.w: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: A = None
        self.w: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: G = None
        self.q: J = None
        self.p: A = None
        self.r: A = None
        self.v: C = None
        self.z: D = None
        self.u: J = None
        self.y: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.v: B = None
        self.o: E = None
        self.u: H = None
        self.p: J = None
        self.t: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: C = None
        self.v: A = None
        self.o: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: I = None
        self.r: C = None
        self.u: B = None
        self.s: G = None
        self.q: E = None
        self.txt = txt

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

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

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

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