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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: A = None
        self.t: H = None
        self.y: E = None
        self.p: I = None
        self.u: B = None
        self.r: D = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: C = None
        self.x: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: A = None
        self.x: B = None
        self.txt = txt

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.s: A = None
        self.t: H = None
        self.y: E = None
        self.p: I = None
        self.u: B = None
        self.r: D = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.o: C = None
        self.w: C = None
        self.x: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: A = None
        self.x: B = None
        self.txt = txt

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

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