class A:
    def __init__(self, txt: str):
        self.v: F = None
        self.q: H = None
        self.z: E = None
        self.t: E = None
        self.p: C = None
        self.o: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: E = None
        self.s: D = None
        self.x: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: B = None
        self.v: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.w: E = None
        self.o: F = None
        self.r: F = None
        self.v: G = None
        self.z: H = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: E = None
        self.s: D = None
        self.x: A = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: B = None
        self.v: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.w: E = None
        self.o: F = None
        self.r: F = None
        self.v: G = None
        self.z: H = None
        self.txt = txt

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

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

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

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