class A:
    def __init__(self, txt: str):
        self.v: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: C = None
        self.t: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: I = None
        self.o: I = None
        self.u: B = None
        self.z: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.o: D = None
        self.v: H = None
        self.z: C = None
        self.y: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.u: E = None
        self.x: I = None
        self.o: E = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.x: C = None
        self.u: E = None
        self.p: F = None
        self.q: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.r: F = None
        self.q: C = None
        self.t: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: I = None
        self.o: I = None
        self.u: B = None
        self.z: B = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: H = None
        self.o: D = None
        self.v: H = None
        self.z: C = None
        self.y: A = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.u: E = None
        self.x: I = None
        self.o: E = None
        self.z: D = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.x: C = None
        self.u: E = None
        self.p: F = None
        self.q: A = None
        self.txt = txt

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

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