class A:
    def __init__(self, txt: str):
        self.o: D = None
        self.q: F = None
        self.x: H = None
        self.y: G = None
        self.z: G = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.s: G = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: G = None
        self.z: A = None
        self.t: B = None
        self.o: A = None
        self.r: B = None
        self.w: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.v: C = None
        self.w: G = None
        self.s: G = None
        self.o: A = None
        self.r: F = None
        self.u: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: E = None
        self.w: B = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: G = None
        self.q: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: G = None
        self.z: A = None
        self.t: B = None
        self.o: A = None
        self.r: B = None
        self.w: G = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.z: D = None
        self.v: C = None
        self.w: G = None
        self.s: G = None
        self.o: A = None
        self.r: F = None
        self.u: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: E = None
        self.y: E = None
        self.w: B = None
        self.txt = txt

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

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