class A:
    def __init__(self, txt: str):
        self.q: G = None
        self.p: E = None
        self.s: F = None
        self.x: J = None
        self.r: B = None
        self.t: G = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.r: J = None
        self.w: C = None
        self.o: C = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: G = None
        self.v: I = None
        self.q: I = None
        self.y: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.s: G = None
        self.w: G = None
        self.z: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: J = None
        self.x: J = None
        self.t: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: H = None
        self.w: C = None
        self.r: B = None
        self.o: A = None
        self.x: F = None
        self.u: G = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.r: J = None
        self.w: C = None
        self.o: C = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: G = None
        self.v: I = None
        self.q: I = None
        self.y: B = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: G = None
        self.s: G = None
        self.w: G = None
        self.z: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: J = None
        self.x: J = None
        self.t: F = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: H = None
        self.w: C = None
        self.r: B = None
        self.o: A = None
        self.x: F = None
        self.u: G = None
        self.txt = txt

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

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