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

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

class C:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: F = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: B = None
        self.t: A = None
        self.p: G = None
        self.q: A = None
        self.z: H = None
        self.s: G = None
        self.r: J = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: H = None
        self.x: B = None
        self.z: H = None
        self.y: B = None
        self.p: J = None
        self.w: J = None
        self.q: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: H = None
        self.o: A = None
        self.x: F = None
        self.q: H = None
        self.v: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: B = None
        self.q: H = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: F = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.w: B = None
        self.t: A = None
        self.p: G = None
        self.q: A = None
        self.z: H = None
        self.s: G = None
        self.r: J = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: H = None
        self.x: B = None
        self.z: H = None
        self.y: B = None
        self.p: J = None
        self.w: J = None
        self.q: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: H = None
        self.o: A = None
        self.x: F = None
        self.q: H = None
        self.v: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.z: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: F = None
        self.o: B = None
        self.q: H = None
        self.txt = txt

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

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