class A:
    def __init__(self, txt: str):
        self.s: C = None
        self.v: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.q: G = None
        self.x: G = None
        self.r: B = None
        self.s: G = None
        self.v: E = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.x: H = None
        self.o: H = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.z: G = None
        self.q: G = None
        self.x: G = None
        self.r: B = None
        self.s: G = None
        self.v: E = None
        self.txt = txt

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.x: H = None
        self.o: H = None
        self.txt = txt

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

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

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