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

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

class C:
    def __init__(self, txt: str):
        self.z: A = None
        self.v: A = None
        self.x: F = None
        self.o: E = None
        self.u: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: G = None
        self.q: A = None
        self.u: C = None
        self.r: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.x: E = None
        self.t: E = None
        self.o: E = None
        self.u: A = None
        self.w: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.s: E = None
        self.q: F = None
        self.u: G = None
        self.t: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

k = A("k")
n = B("n")
e = C("e")
f = D("f")
c = E("c")
m = F("m")
l = G("l")
d = H("d")
j = I("j")
h = B("h")

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

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

class C:
    def __init__(self, txt: str):
        self.z: A = None
        self.v: A = None
        self.x: F = None
        self.o: E = None
        self.u: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.y: G = None
        self.q: A = None
        self.u: C = None
        self.r: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.x: E = None
        self.t: E = None
        self.o: E = None
        self.u: A = None
        self.w: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: D = None
        self.s: E = None
        self.q: F = None
        self.u: G = None
        self.t: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

k = A("k")
n = B("n")
e = C("e")
f = D("f")
c = E("c")
m = F("m")
l = G("l")
d = H("d")
j = I("j")
h = B("h")

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