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

class B:
    def __init__(self, txt: str):
        self.u: J = None
        self.y: D = None
        self.v: F = None
        self.p: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.o: I = None
        self.s: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: I = None
        self.r: I = None
        self.o: J = None
        self.v: D = None
        self.t: G = None
        self.q: G = None
        self.w: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.o: A = None
        self.v: F = None
        self.w: A = None
        self.t: H = None
        self.x: F = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.u: J = None
        self.y: D = None
        self.v: F = None
        self.p: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.r: G = None
        self.x: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: C = None
        self.o: I = None
        self.s: E = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.p: I = None
        self.r: I = None
        self.o: J = None
        self.v: D = None
        self.t: G = None
        self.q: G = None
        self.w: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: E = None
        self.o: A = None
        self.v: F = None
        self.w: A = None
        self.t: H = None
        self.x: F = None
        self.txt = txt

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

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

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

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

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