class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.s: D = None
        self.q: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: G = None
        self.s: E = None
        self.y: F = None
        self.r: J = None
        self.o: J = None
        self.txt = txt

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

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

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

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

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

class H:
    def __init__(self, txt: str):
        self.z: E = None
        self.r: E = None
        self.w: D = None
        self.y: A = None
        self.t: A = None
        self.o: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: A = None
        self.u: I = None
        self.x: B = None
        self.r: D = None
        self.s: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: G = None
        self.s: E = None
        self.y: F = None
        self.r: J = None
        self.o: J = None
        self.txt = txt

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

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

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

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

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

class H:
    def __init__(self, txt: str):
        self.z: E = None
        self.r: E = None
        self.w: D = None
        self.y: A = None
        self.t: A = None
        self.o: E = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.z: E = None
        self.y: A = None
        self.u: I = None
        self.x: B = None
        self.r: D = None
        self.s: C = None
        self.txt = txt

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

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