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

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

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

class D:
    def __init__(self, txt: str):
        self.y: C = None
        self.u: A = None
        self.x: C = None
        self.r: E = None
        self.p: G = None
        self.t: F = None
        self.s: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.v: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: B = None
        self.w: G = None
        self.x: H = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.y: C = None
        self.u: A = None
        self.x: C = None
        self.r: E = None
        self.p: G = None
        self.t: F = None
        self.s: B = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.p: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: B = None
        self.v: F = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.p: B = None
        self.w: G = None
        self.x: H = None
        self.txt = txt

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

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