class A:
    def __init__(self, txt: str):
        self.t: I = None
        self.o: D = None
        self.w: H = None
        self.p: H = None
        self.y: G = None
        self.u: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: G = None
        self.z: I = None
        self.r: D = None
        self.q: E = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.x: A = None
        self.q: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.o: B = None
        self.s: C = None
        self.txt = txt

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

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

g = A("g")
b = B("b")
h = C("h")
i = D("i")
e = E("e")
d = F("d")
k = G("k")
m = H("m")
l = I("l")
n = J("n")

g.t = l
g.o = i
g.w = m
g.p = m
g.y = k
g.u = e
b.p = h
h.x = k
h.z = l
h.r = i
h.q = e
i.p = l
i.w = g
i.y = g
i.s = e
i.o = b
i.u = b
i.z = m
i.q = d
i.t = k
e.t = h
d.q = i
d.o = i
d.r = i
d.s = h
d.x = h
d.v = b
k.x = g
k.q = g
m.u = b
m.o = b
m.s = h
l.v = i
l.s = i
l.o = i
l.w = e
l.z = e
l.t = d
l.q = b
n.o = g
n.x = m
n.z = m
assert i.z.u.p.x.txt == "
class A:
    def __init__(self, txt: str):
        self.t: I = None
        self.o: D = None
        self.w: H = None
        self.p: H = None
        self.y: G = None
        self.u: E = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: G = None
        self.z: I = None
        self.r: D = None
        self.q: E = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.x: A = None
        self.q: A = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: B = None
        self.o: B = None
        self.s: C = None
        self.txt = txt

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

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

g = A("g")
b = B("b")
h = C("h")
i = D("i")
e = E("e")
d = F("d")
k = G("k")
m = H("m")
l = I("l")
n = J("n")

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