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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.w: G = None
        self.z: D = None
        self.y: J = 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.s: J = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.r: J = None
        self.z: E = None
        self.u: D = None
        self.w: E = None
        self.v: B = None
        self.t: B = None
        self.p: H = None
        self.s: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: B = None
        self.z: G = None
        self.w: G = None
        self.r: J = None
        self.o: J = None
        self.s: B = None
        self.y: G = None
        self.q: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: C = None
        self.x: A = None
        self.s: F = None
        self.y: A = None
        self.z: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: A = None
        self.r: B = None
        self.s: I = None
        self.x: D = None
        self.o: B = None
        self.t: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: D = None
        self.w: G = None
        self.z: D = None
        self.y: J = 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.s: J = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.r: J = None
        self.z: E = None
        self.u: D = None
        self.w: E = None
        self.v: B = None
        self.t: B = None
        self.p: H = None
        self.s: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: B = None
        self.z: G = None
        self.w: G = None
        self.r: J = None
        self.o: J = None
        self.s: B = None
        self.y: G = None
        self.q: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: C = None
        self.x: A = None
        self.s: F = None
        self.y: A = None
        self.z: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.z: A = None
        self.r: B = None
        self.s: I = None
        self.x: D = None
        self.o: B = None
        self.t: E = None
        self.txt = txt

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

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