class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.p: I = None
        self.w: F = None
        self.o: J = None
        self.u: E = None
        self.t: J = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: I = None
        self.u: E = None
        self.z: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: B = None
        self.v: G = None
        self.y: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: H = None
        self.s: B = None
        self.w: B = None
        self.q: C = None
        self.p: I = None
        self.x: I = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: B = None
        self.p: H = None
        self.o: C = None
        self.z: D = None
        self.s: D = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.x: I = None
        self.u: E = None
        self.z: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: B = None
        self.v: G = None
        self.y: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: H = None
        self.s: B = None
        self.w: B = None
        self.q: C = None
        self.p: I = None
        self.x: I = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: B = None
        self.p: H = None
        self.o: C = None
        self.z: D = None
        self.s: D = None
        self.txt = txt

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

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

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