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

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.x: C = None
        self.v: D = None
        self.q: A = None
        self.o: I = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: D = None
        self.r: A = None
        self.z: H = None
        self.v: C = None
        self.q: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.w: B = None
        self.p: B = None
        self.x: F = None
        self.u: B = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: F = None
        self.u: B = None
        self.p: E = None
        self.o: D = None
        self.z: G = None
        self.t: E = None
        self.y: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.x: C = None
        self.v: D = None
        self.q: A = None
        self.o: I = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: D = None
        self.r: A = None
        self.z: H = None
        self.v: C = None
        self.q: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.v: D = None
        self.w: B = None
        self.p: B = None
        self.x: F = None
        self.u: B = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: F = None
        self.u: B = None
        self.p: E = None
        self.o: D = None
        self.z: G = None
        self.t: E = None
        self.y: E = None
        self.txt = txt

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

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