class A:
    def __init__(self, txt: str):
        self.p: H = None
        self.v: F = None
        self.t: J = None
        self.o: J = None
        self.r: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: C = None
        self.r: A = None
        self.o: I = None
        self.z: J = None
        self.t: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.s: J = None
        self.z: G = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.u: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.p: C = None
        self.r: A = None
        self.o: I = None
        self.z: J = None
        self.t: A = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: E = None
        self.s: J = None
        self.z: G = None
        self.txt = txt

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

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

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

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