class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.x: I = None
        self.p: G = None
        self.y: G = None
        self.u: D = None
        self.v: H = None
        self.t: G = None
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: I = None
        self.x: H = None
        self.v: D = None
        self.txt = txt

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

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

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

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

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

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

f.z = a
j.w = m
j.x = e
j.p = i
j.y = i
j.t = i
j.u = b
j.q = b
j.v = c
a.o = f
b.r = i
b.x = k
m.u = e
m.x = c
m.v = b
d.x = e
i.v = b
i.z = d
c.r = f
c.u = m
c.w = m
c.z = m
c.x = k
c.s = b
c.v = i
c.q = i
c.y = d
e.z = c
e.y = c
e.r = f
e.q = f
e.v = k
e.w = d
e.u = j
k.r = j
k.w = j
k.y = c
k.o = m
k.z = m
k.v = a
k.p = a
k.q = d
k.t = d
assert j.p.v.x.txt == "
class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.x: I = None
        self.p: G = None
        self.y: G = None
        self.u: D = None
        self.v: H = None
        self.t: G = None
        self.q: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: J = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: I = None
        self.x: H = None
        self.v: D = None
        self.txt = txt

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

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

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

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

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

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

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