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

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.o: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: A = None
        self.w: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.y: E = None
        self.t: B = None
        self.u: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: A = None
        self.y: F = None
        self.z: D = None
        self.w: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: I = None
        self.v: J = None
        self.r: I = None
        self.w: I = None
        self.o: G = None
        self.z: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.o: G = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: A = None
        self.w: F = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: B = None
        self.y: E = None
        self.t: B = None
        self.u: G = None
        self.v: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: A = None
        self.y: F = None
        self.z: D = None
        self.w: J = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: I = None
        self.v: J = None
        self.r: I = None
        self.w: I = None
        self.o: G = None
        self.z: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.p: A = None
        self.txt = txt

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

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