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

class B:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: G = None
        self.v: H = None
        self.y: G = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: A = None
        self.y: B = None
        self.x: I = None
        self.s: G = None
        self.w: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.y: F = None
        self.s: A = None
        self.r: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.p: F = None
        self.t: E = None
        self.z: F = None
        self.s: G = None
        self.r: D = None
        self.q: G = None
        self.w: E = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.q: F = None
        self.o: G = None
        self.v: H = None
        self.y: G = None
        self.u: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: D = None
        self.z: A = None
        self.y: B = None
        self.x: I = None
        self.s: G = None
        self.w: B = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: B = None
        self.y: F = None
        self.s: A = None
        self.r: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.p: F = None
        self.t: E = None
        self.z: F = None
        self.s: G = None
        self.r: D = None
        self.q: G = None
        self.w: E = None
        self.txt = txt

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

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

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