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

class B:
    def __init__(self, txt: str):
        self.s: F = None
        self.t: C = None
        self.p: E = None
        self.r: A = None
        self.q: A = None
        self.w: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.s: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.p: G = None
        self.v: D = None
        self.o: F = None
        self.t: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: F = None
        self.p: D = None
        self.t: F = None
        self.y: B = None
        self.q: D = None
        self.z: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.o: A = None
        self.txt = txt

i = A("i")
h = B("h")
f = C("f")
b = D("b")
c = E("c")
d = F("d")
a = G("a")
e = D("e")
k = F("k")
m = C("m")

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

class B:
    def __init__(self, txt: str):
        self.s: F = None
        self.t: C = None
        self.p: E = None
        self.r: A = None
        self.q: A = None
        self.w: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: F = None
        self.s: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: B = None
        self.p: G = None
        self.v: D = None
        self.o: F = None
        self.t: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.s: F = None
        self.p: D = None
        self.t: F = None
        self.y: B = None
        self.q: D = None
        self.z: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: D = None
        self.o: A = None
        self.txt = txt

i = A("i")
h = B("h")
f = C("f")
b = D("b")
c = E("c")
d = F("d")
a = G("a")
e = D("e")
k = F("k")
m = C("m")

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