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

class B:
    def __init__(self, txt: str):
        self.w: D = None
        self.x: I = None
        self.o: G = None
        self.y: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.w: I = None
        self.t: I = None
        self.o: D = None
        self.y: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: A = None
        self.y: F = None
        self.q: F = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.w: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.w: A = None
        self.r: D = None
        self.s: B = None
        self.z: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.w: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.w: D = None
        self.x: I = None
        self.o: G = None
        self.y: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.w: I = None
        self.t: I = None
        self.o: D = None
        self.y: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: A = None
        self.y: F = None
        self.q: F = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.w: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.w: A = None
        self.r: D = None
        self.s: B = None
        self.z: E = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.w: B = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: C = None
        self.txt = txt

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

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