class A:
    def __init__(self, txt: str):
        self.x: J = None
        self.o: D = None
        self.q: H = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.r: J = None
        self.u: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: C = None
        self.x: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: C = None
        self.r: D = None
        self.w: A = None
        self.t: D = None
        self.p: C = None
        self.txt = txt

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

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

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.r: J = None
        self.u: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: C = None
        self.x: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: C = None
        self.r: D = None
        self.w: A = None
        self.t: D = None
        self.p: C = None
        self.txt = txt

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

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

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

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

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