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

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.r: J = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: I = None
        self.y: H = None
        self.z: G = None
        self.u: A = None
        self.v: J = None
        self.r: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.u: I = None
        self.r: G = None
        self.x: C = None
        self.w: C = None
        self.o: B = None
        self.t: B = None
        self.q: A = None
        self.s: A = None
        self.y: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.z: C = None
        self.p: A = None
        self.r: I = None
        self.w: B = None
        self.x: J = None
        self.o: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: A = None
        self.o: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: J = None
        self.u: D = None
        self.s: D = None
        self.q: J = None
        self.t: I = None
        self.y: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: B = None
        self.q: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: C = None
        self.r: J = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: I = None
        self.y: H = None
        self.z: G = None
        self.u: A = None
        self.v: J = None
        self.r: I = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.u: I = None
        self.r: G = None
        self.x: C = None
        self.w: C = None
        self.o: B = None
        self.t: B = None
        self.q: A = None
        self.s: A = None
        self.y: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.z: C = None
        self.p: A = None
        self.r: I = None
        self.w: B = None
        self.x: J = None
        self.o: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.s: A = None
        self.o: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: J = None
        self.u: D = None
        self.s: D = None
        self.q: J = None
        self.t: I = None
        self.y: G = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.z: J = None
        self.p: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.s: B = None
        self.q: D = None
        self.txt = txt

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

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