class A:
    def __init__(self, txt: str):
        self.q: F = None
        self.x: I = None
        self.s: G = None
        self.w: D = None
        self.t: G = None
        self.u: J = None
        self.y: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: A = None
        self.r: H = None
        self.v: J = None
        self.o: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: F = None
        self.x: B = None
        self.v: G = None
        self.t: H = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.w: D = None
        self.v: F = None
        self.o: J = None
        self.u: D = None
        self.s: C = None
        self.q: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: A = None
        self.r: E = None
        self.y: F = None
        self.z: A = None
        self.p: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: A = None
        self.r: H = None
        self.v: J = None
        self.o: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: F = None
        self.x: B = None
        self.v: G = None
        self.t: H = None
        self.txt = txt

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

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

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

class H:
    def __init__(self, txt: str):
        self.r: C = None
        self.w: D = None
        self.v: F = None
        self.o: J = None
        self.u: D = None
        self.s: C = None
        self.q: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: A = None
        self.r: E = None
        self.y: F = None
        self.z: A = None
        self.p: H = None
        self.txt = txt

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

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