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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.v: G = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.p: A = None
        self.o: B = None
        self.t: H = None
        self.x: A = None
        self.w: F = None
        self.q: D = None
        self.z: H = None
        self.txt = txt

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

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.v: G = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.p: A = None
        self.o: B = None
        self.t: H = None
        self.x: A = None
        self.w: F = None
        self.q: D = None
        self.z: H = None
        self.txt = txt

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

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