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

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: E = None
        self.z: E = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: G = None
        self.t: I = None
        self.x: G = None
        self.o: G = None
        self.w: H = None
        self.u: H = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: A = None
        self.t: C = None
        self.w: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: F = None
        self.z: C = None
        self.v: A = None
        self.txt = txt

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

e.y = n
i.s = n
k.w = a
k.z = a
b.u = h
b.t = h
a.s = e
a.x = e
a.z = e
a.o = e
a.t = e
a.w = h
a.v = c
a.y = i
a.u = g
c.q = e
c.s = g
c.x = g
c.o = g
c.t = n
c.w = h
c.u = h
c.z = a
g.t = k
h.x = e
h.t = k
h.w = i
n.w = c
n.z = k
n.v = e
assert g.t.z.z.y.txt == "
class A:
    def __init__(self, txt: str):
        self.y: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.w: E = None
        self.z: E = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: G = None
        self.t: I = None
        self.x: G = None
        self.o: G = None
        self.w: H = None
        self.u: H = None
        self.z: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.x: A = None
        self.t: C = None
        self.w: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.w: F = None
        self.z: C = None
        self.v: A = None
        self.txt = txt

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

e.y = n
i.s = n
k.w = a
k.z = a
b.u = h
b.t = h
a.s = e
a.x = e
a.z = e
a.o = e
a.t = e
a.w = h
a.v = c
a.y = i
a.u = g
c.q = e
c.s = g
c.x = g
c.o = g
c.t = n
c.w = h
c.u = h
c.z = a
g.t = k
h.x = e
h.t = k
h.w = i
n.w = c
n.z = k
n.v = e
assert g.t.z.z.y.txt == "n"