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

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

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

class D:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: A = None
        self.y: B = None
        self.x: A = None
        self.v: C = None
        self.t: A = None
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.t: B = None
        self.w: D = None
        self.o: B = None
        self.p: C = None
        self.r: D = None
        self.v: E = None
        self.s: A = None
        self.txt = txt

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

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

n = A("n")
g = B("g")
e = C("e")
a = D("a")
m = E("m")
c = F("c")
h = G("h")
l = H("l")
j = E("j")
b = G("b")

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

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

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

class D:
    def __init__(self, txt: str):
        self.q: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: A = None
        self.y: B = None
        self.x: A = None
        self.v: C = None
        self.t: A = None
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.x: H = None
        self.t: B = None
        self.w: D = None
        self.o: B = None
        self.p: C = None
        self.r: D = None
        self.v: E = None
        self.s: A = None
        self.txt = txt

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

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

n = A("n")
g = B("g")
e = C("e")
a = D("a")
m = E("m")
c = F("c")
h = G("h")
l = H("l")
j = E("j")
b = G("b")

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