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

class B:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: H = None
        self.y: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: G = None
        self.t: F = None
        self.v: C = None
        self.u: B = None
        self.o: E = None
        self.x: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: I = None
        self.s: F = None
        self.v: J = None
        self.p: H = None
        self.u: I = None
        self.o: A = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.s: D = None
        self.p: C = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: E = None
        self.o: I = None
        self.p: I = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: A = None
        self.z: H = None
        self.y: J = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.r: G = None
        self.t: F = None
        self.v: C = None
        self.u: B = None
        self.o: E = None
        self.x: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: I = None
        self.s: F = None
        self.v: J = None
        self.p: H = None
        self.u: I = None
        self.o: A = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.s: D = None
        self.p: C = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: E = None
        self.o: I = None
        self.p: I = None
        self.txt = txt

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

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