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

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

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.u: G = None
        self.r: F = None
        self.z: I = None
        self.w: D = None
        self.x: I = None
        self.txt = txt

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

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

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

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

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

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

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.q: D = None
        self.s: C = None
        self.v: G = None
        self.o: G = None
        self.txt = txt

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

f.w = i
f.q = i
f.p = d
f.o = h
f.x = n
f.y = g
f.s = a
h.p = d
h.w = g
g.y = j
g.z = j
g.x = j
g.u = m
g.r = k
g.w = a
a.p = h
a.w = j
a.q = n
a.r = n
a.u = d
a.x = d
a.t = g
a.o = i
d.u = h
d.o = i
k.x = i
k.v = f
k.w = d
k.y = d
k.p = d
k.t = g
k.z = m
k.o = m
k.s = j
k.u = h
m.u = a
m.r = n
m.p = j
m.t = k
i.x = j
i.z = j
i.u = j
i.t = g
i.w = f
i.r = d
i.y = k
i.p = m
j.o = a
j.z = a
j.r = h
j.s = h
j.y = h
j.v = n
j.w = m
j.u = m
j.x = g
j.q = d
n.u = i
n.q = a
n.s = g
n.v = m
n.o = m
assert k.v.o.w.z.s.w.txt == "
class A:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: E = None
        self.o: B = None
        self.x: J = None
        self.y: C = None
        self.q: H = None
        self.s: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.y: I = None
        self.u: G = None
        self.r: F = None
        self.z: I = None
        self.w: D = None
        self.x: I = None
        self.txt = txt

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

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

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

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

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

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

class J:
    def __init__(self, txt: str):
        self.u: H = None
        self.q: D = None
        self.s: C = None
        self.v: G = None
        self.o: G = None
        self.txt = txt

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

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