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

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

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.q: F = None
        self.o: D = None
        self.u: I = None
        self.x: A = None
        self.s: D = None
        self.v: E = None
        self.p: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.w: C = None
        self.o: I = None
        self.u: D = None
        self.q: G = None
        self.v: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.w: I = None
        self.v: I = None
        self.z: B = None
        self.y: I = None
        self.r: F = None
        self.x: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.r: D = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.w: D = None
        self.q: F = None
        self.o: D = None
        self.u: I = None
        self.x: A = None
        self.s: D = None
        self.v: E = None
        self.p: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.y: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: D = None
        self.w: C = None
        self.o: I = None
        self.u: D = None
        self.q: G = None
        self.v: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.w: I = None
        self.v: I = None
        self.z: B = None
        self.y: I = None
        self.r: F = None
        self.x: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.r: D = None
        self.txt = txt

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

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