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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.q: H = None
        self.t: H = None
        self.r: F = None
        self.x: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.r: G = None
        self.v: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.v: A = None
        self.z: C = None
        self.q: G = None
        self.y: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.v: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.y: A = None
        self.u: G = None
        self.t: G = None
        self.o: I = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.q: I = None
        self.r: C = None
        self.x: H = None
        self.t: H = None
        self.s: D = None
        self.z: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.q: H = None
        self.t: H = None
        self.r: F = None
        self.x: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.r: G = None
        self.v: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: E = None
        self.v: A = None
        self.z: C = None
        self.q: G = None
        self.y: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.v: I = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.y: A = None
        self.u: G = None
        self.t: G = None
        self.o: I = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.q: I = None
        self.r: C = None
        self.x: H = None
        self.t: H = None
        self.s: D = None
        self.z: A = None
        self.txt = txt

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

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