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

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

class C:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: A = None
        self.r: G = None
        self.s: I = None
        self.q: G = None
        self.p: A = None
        self.x: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: E = None
        self.p: B = None
        self.t: J = None
        self.q: A = None
        self.x: H = None
        self.z: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: J = None
        self.v: E = None
        self.o: J = None
        self.z: G = None
        self.x: I = None
        self.w: D = None
        self.q: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: E = None
        self.o: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: G = None
        self.x: G = None
        self.z: I = None
        self.o: F = None
        self.r: D = None
        self.y: E = None
        self.u: A = None
        self.t: I = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.t: A = None
        self.y: A = None
        self.r: G = None
        self.s: I = None
        self.q: G = None
        self.p: A = None
        self.x: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: E = None
        self.p: B = None
        self.t: J = None
        self.q: A = None
        self.x: H = None
        self.z: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: J = None
        self.v: E = None
        self.o: J = None
        self.z: G = None
        self.x: I = None
        self.w: D = None
        self.q: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.z: E = None
        self.o: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.v: G = None
        self.x: G = None
        self.z: I = None
        self.o: F = None
        self.r: D = None
        self.y: E = None
        self.u: A = None
        self.t: I = None
        self.txt = txt

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

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