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

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

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

class D:
    def __init__(self, txt: str):
        self.u: A = None
        self.v: I = None
        self.w: J = None
        self.x: E = None
        self.s: J = None
        self.o: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: J = None
        self.q: H = None
        self.u: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.v: D = None
        self.p: C = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.t: H = None
        self.u: F = None
        self.r: C = None
        self.txt = txt

d = A("d")
m = B("m")
h = C("h")
a = D("a")
b = E("b")
k = F("k")
i = G("i")
g = H("g")
j = I("j")
f = J("f")

d.t = g
d.w = f
d.q = f
d.s = m
d.y = k
d.p = k
d.v = k
d.u = a
d.z = a
d.o = b
m.o = k
m.s = d
m.q = d
m.t = f
m.w = j
m.v = j
m.p = j
m.x = a
m.z = h
h.q = j
h.o = j
h.p = k
a.u = d
a.o = d
a.v = j
a.w = f
a.s = f
a.x = b
b.w = f
b.q = g
b.u = m
k.u = i
k.v = h
k.p = j
k.o = a
k.t = f
i.r = b
i.v = a
i.p = h
g.p = a
g.w = m
g.y = k
j.o = g
j.x = h
f.t = g
f.u = k
f.r = h
assert d.u.x.u.x.txt == "
class A:
    def __init__(self, txt: str):
        self.t: H = None
        self.w: J = None
        self.q: J = None
        self.s: B = None
        self.y: F = None
        self.u: D = None
        self.z: D = None
        self.p: F = None
        self.v: F = None
        self.o: E = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.u: A = None
        self.v: I = None
        self.w: J = None
        self.x: E = None
        self.s: J = None
        self.o: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: J = None
        self.q: H = None
        self.u: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.r: E = None
        self.v: D = None
        self.p: C = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.t: H = None
        self.u: F = None
        self.r: C = None
        self.txt = txt

d = A("d")
m = B("m")
h = C("h")
a = D("a")
b = E("b")
k = F("k")
i = G("i")
g = H("g")
j = I("j")
f = J("f")

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