class A:
    def __init__(self, txt: str):
        self.o: B = None
        self.w: C = None
        self.q: H = None
        self.z: D = None
        self.s: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: H = None
        self.v: D = None
        self.q: D = None
        self.o: E = None
        self.p: G = None
        self.u: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: A = None
        self.o: G = None
        self.p: G = None
        self.w: G = None
        self.v: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: H = None
        self.t: A = None
        self.y: H = None
        self.u: F = None
        self.q: F = None
        self.x: A = None
        self.v: C = None
        self.w: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: B = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: B = None
        self.o: E = None
        self.s: C = None
        self.y: H = None
        self.r: C = None
        self.q: E = None
        self.w: D = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: G = None
        self.r: F = None
        self.y: E = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.z: D = None
        self.t: H = None
        self.v: D = None
        self.q: D = None
        self.o: E = None
        self.p: G = None
        self.u: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: A = None
        self.o: G = None
        self.p: G = None
        self.w: G = None
        self.v: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: H = None
        self.t: A = None
        self.y: H = None
        self.u: F = None
        self.q: F = None
        self.x: A = None
        self.v: C = None
        self.w: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: B = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.p: B = None
        self.o: E = None
        self.s: C = None
        self.y: H = None
        self.r: C = None
        self.q: E = None
        self.w: D = None
        self.x: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.w: G = None
        self.r: F = None
        self.y: E = None
        self.txt = txt

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

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