class A:
    def __init__(self, txt: str):
        self.z: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: A = None
        self.p: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: I = None
        self.t: E = None
        self.y: G = None
        self.r: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: I = None
        self.v: C = None
        self.y: G = None
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: G = None
        self.x: C = None
        self.r: E = None
        self.s: E = None
        self.y: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: B = None
        self.o: A = None
        self.x: A = None
        self.u: H = None
        self.v: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.t: A = None
        self.p: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: I = None
        self.t: E = None
        self.y: G = None
        self.r: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: I = None
        self.v: C = None
        self.y: G = None
        self.t: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: G = None
        self.x: C = None
        self.r: E = None
        self.s: E = None
        self.y: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.r: D = None
        self.s: B = None
        self.o: A = None
        self.x: A = None
        self.u: H = None
        self.v: E = None
        self.txt = txt

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

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