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

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

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: J = None
        self.w: C = None
        self.q: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.p: A = None
        self.u: J = None
        self.q: B = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.p: G = None
        self.t: J = None
        self.o: E = None
        self.v: A = None
        self.txt = txt

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: I = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: J = None
        self.w: C = None
        self.q: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.p: A = None
        self.u: J = None
        self.q: B = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.p: G = None
        self.t: J = None
        self.o: E = None
        self.v: A = None
        self.txt = txt

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

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

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