class A:
    def __init__(self, txt: str):
        self.y: I = None
        self.w: I = None
        self.r: I = None
        self.z: C = None
        self.txt = txt

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

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

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

class E:
    def __init__(self, txt: str):
        self.z: J = None
        self.v: I = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: J = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.u: D = None
        self.r: G = None
        self.s: F = None
        self.w: E = None
        self.x: D = None
        self.y: D = None
        self.z: H = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.z: J = None
        self.v: I = None
        self.w: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: J = None
        self.txt = txt

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

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

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

class J:
    def __init__(self, txt: str):
        self.u: D = None
        self.r: G = None
        self.s: F = None
        self.w: E = None
        self.x: D = None
        self.y: D = None
        self.z: H = None
        self.txt = txt

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

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