class A:
    def __init__(self, txt: str):
        self.t: E = None
        self.z: J = None
        self.p: G = None
        self.u: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: J = None
        self.w: B = None
        self.x: F = None
        self.o: E = None
        self.s: F = None
        self.q: B = None
        self.y: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.t: C = None
        self.v: J = None
        self.txt = txt

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

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: J = None
        self.w: B = None
        self.x: F = None
        self.o: E = None
        self.s: F = None
        self.q: B = None
        self.y: A = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.t: C = None
        self.v: J = None
        self.txt = txt

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

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

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

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

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

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