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

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

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

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: F = None
        self.s: F = None
        self.u: D = None
        self.v: H = None
        self.txt = txt

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

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

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

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

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

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

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

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

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

class I:
    def __init__(self, txt: str):
        self.x: F = None
        self.s: F = None
        self.u: D = None
        self.v: H = None
        self.txt = txt

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

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