class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.p: I = None
        self.s: J = None
        self.r: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.u: I = None
        self.p: I = None
        self.z: G = None
        self.w: C = None
        self.o: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: J = None
        self.y: F = None
        self.v: D = None
        self.p: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: C = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: C = None
        self.w: C = None
        self.x: A = None
        self.v: B = None
        self.p: B = None
        self.y: I = None
        self.r: G = None
        self.q: A = None
        self.z: H = None
        self.t: G = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.z: B = None
        self.o: F = None
        self.y: F = None
        self.s: D = None
        self.p: A = None
        self.u: H = None
        self.r: G = None
        self.x: A = None
        self.t: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.y: G = None
        self.u: I = None
        self.p: I = None
        self.z: G = None
        self.w: C = None
        self.o: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: J = None
        self.y: F = None
        self.v: D = None
        self.p: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: C = None
        self.o: G = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: C = None
        self.w: C = None
        self.x: A = None
        self.v: B = None
        self.p: B = None
        self.y: I = None
        self.r: G = None
        self.q: A = None
        self.z: H = None
        self.t: G = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.z: B = None
        self.o: F = None
        self.y: F = None
        self.s: D = None
        self.p: A = None
        self.u: H = None
        self.r: G = None
        self.x: A = None
        self.t: F = None
        self.txt = txt

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

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