class A:
    def __init__(self, txt: str):
        self.u: E = None
        self.s: D = None
        self.x: G = None
        self.o: G = None
        self.w: J = None
        self.r: D = None
        self.p: H = None
        self.v: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.s: A = None
        self.y: E = None
        self.q: D = None
        self.w: A = None
        self.o: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: J = None
        self.z: B = None
        self.t: A = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.w: A = None
        self.u: I = None
        self.q: C = None
        self.y: I = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: G = None
        self.q: C = None
        self.o: G = None
        self.s: A = None
        self.x: J = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.s: A = None
        self.y: E = None
        self.q: D = None
        self.w: A = None
        self.o: I = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: J = None
        self.z: B = None
        self.t: A = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.w: A = None
        self.u: I = None
        self.q: C = None
        self.y: I = None
        self.s: E = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.y: G = None
        self.q: C = None
        self.o: G = None
        self.s: A = None
        self.x: J = None
        self.txt = txt

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

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

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