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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: E = None
        self.w: I = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: B = None
        self.u: E = None
        self.q: J = None
        self.y: G = None
        self.s: G = None
        self.p: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: J = None
        self.q: I = None
        self.s: J = None
        self.r: C = None
        self.v: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.q: D = None
        self.v: F = None
        self.z: G = None
        self.u: C = None
        self.t: G = None
        self.o: D = None
        self.y: J = None
        self.w: H = None
        self.s: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: B = None
        self.v: J = None
        self.w: D = None
        self.t: H = None
        self.p: I = None
        self.s: B = None
        self.y: J = None
        self.u: C = None
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.r: G = None
        self.q: I = None
        self.x: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.z: E = None
        self.w: D = None
        self.p: G = None
        self.x: B = None
        self.u: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: B = None
        self.q: D = None
        self.s: E = None
        self.o: C = None
        self.v: A = None
        self.u: H = None
        self.txt = txt

h = A("h")
c = B("c")
k = C("k")
n = D("n")
j = E("j")
b = F("b")
i = G("i")
d = H("d")
g = I("g")
l = J("l")

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

class B:
    def __init__(self, txt: str):
        self.s: D = None
        self.u: E = None
        self.w: I = None
        self.t: J = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.o: B = None
        self.u: E = None
        self.q: J = None
        self.y: G = None
        self.s: G = None
        self.p: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.u: J = None
        self.q: I = None
        self.s: J = None
        self.r: C = None
        self.v: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.q: D = None
        self.v: F = None
        self.z: G = None
        self.u: C = None
        self.t: G = None
        self.o: D = None
        self.y: J = None
        self.w: H = None
        self.s: I = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: B = None
        self.v: J = None
        self.w: D = None
        self.t: H = None
        self.p: I = None
        self.s: B = None
        self.y: J = None
        self.u: C = None
        self.z: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.r: G = None
        self.q: I = None
        self.x: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.v: E = None
        self.z: E = None
        self.w: D = None
        self.p: G = None
        self.x: B = None
        self.u: A = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.t: B = None
        self.q: D = None
        self.s: E = None
        self.o: C = None
        self.v: A = None
        self.u: H = None
        self.txt = txt

h = A("h")
c = B("c")
k = C("k")
n = D("n")
j = E("j")
b = F("b")
i = G("i")
d = H("d")
g = I("g")
l = J("l")

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