class A:
    def __init__(self, txt: str):
        self.r: I = None
        self.y: G = None
        self.z: F = None
        self.q: J = None
        self.t: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: G = None
        self.p: I = None
        self.s: C = None
        self.r: G = None
        self.y: C = None
        self.w: G = None
        self.o: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: A = None
        self.z: G = None
        self.u: E = None
        self.o: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: I = None
        self.t: H = None
        self.p: H = None
        self.u: I = None
        self.x: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: D = None
        self.x: I = None
        self.w: B = None
        self.r: A = None
        self.o: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: F = None
        self.v: F = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: E = None
        self.t: D = None
        self.p: F = None
        self.r: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.v: G = None
        self.p: I = None
        self.s: C = None
        self.r: G = None
        self.y: C = None
        self.w: G = None
        self.o: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: I = None
        self.s: A = None
        self.z: G = None
        self.u: E = None
        self.o: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: I = None
        self.t: H = None
        self.p: H = None
        self.u: I = None
        self.x: C = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.z: D = None
        self.x: I = None
        self.w: B = None
        self.r: A = None
        self.o: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: F = None
        self.v: F = None
        self.u: A = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: E = None
        self.t: D = None
        self.p: F = None
        self.r: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: F = None
        self.txt = txt

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

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