class A:
    def __init__(self, txt: str):
        self.w: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: J = None
        self.q: I = None
        self.v: J = None
        self.p: E = None
        self.z: A = None
        self.s: F = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: H = None
        self.r: I = None
        self.q: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.u: C = None
        self.o: B = None
        self.p: G = None
        self.y: B = None
        self.q: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: D = None
        self.o: E = None
        self.p: B = None
        self.s: A = None
        self.w: C = None
        self.q: D = None
        self.r: E = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.v: I = None
        self.q: G = None
        self.p: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.o: J = None
        self.q: I = None
        self.v: J = None
        self.p: E = None
        self.z: A = None
        self.s: F = None
        self.w: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: H = None
        self.r: I = None
        self.q: I = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.r: J = None
        self.u: C = None
        self.o: B = None
        self.p: G = None
        self.y: B = None
        self.q: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: D = None
        self.o: E = None
        self.p: B = None
        self.s: A = None
        self.w: C = None
        self.q: D = None
        self.r: E = None
        self.txt = txt

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

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

class J:
    def __init__(self, txt: str):
        self.v: I = None
        self.q: G = None
        self.p: C = None
        self.txt = txt

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

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