class A:
    def __init__(self, txt: str):
        self.y: D = None
        self.o: E = None
        self.t: F = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.x: E = None
        self.z: D = None
        self.t: B = None
        self.r: D = None
        self.v: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: I = None
        self.w: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.s: E = None
        self.p: G = None
        self.y: H = None
        self.r: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: E = None
        self.x: E = None
        self.y: C = None
        self.p: F = None
        self.o: I = None
        self.u: I = None
        self.s: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: B = None
        self.u: E = None
        self.z: H = None
        self.y: D = None
        self.v: D = None
        self.x: B = None
        self.t: C = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.s: I = None
        self.x: E = None
        self.z: D = None
        self.t: B = None
        self.r: D = None
        self.v: E = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.p: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: I = None
        self.w: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.v: E = None
        self.s: E = None
        self.p: G = None
        self.y: H = None
        self.r: I = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: E = None
        self.x: E = None
        self.y: C = None
        self.p: F = None
        self.o: I = None
        self.u: I = None
        self.s: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.q: B = None
        self.u: E = None
        self.z: H = None
        self.y: D = None
        self.v: D = None
        self.x: B = None
        self.t: C = None
        self.txt = txt

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

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