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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: F = None
        self.r: B = None
        self.q: I = None
        self.z: B = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: E = None
        self.p: B = None
        self.q: B = None
        self.s: E = None
        self.y: C = None
        self.r: C = None
        self.txt = txt

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

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

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

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

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

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

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

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: F = None
        self.r: B = None
        self.q: I = None
        self.z: B = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: E = None
        self.p: B = None
        self.q: B = None
        self.s: E = None
        self.y: C = None
        self.r: C = None
        self.txt = txt

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

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