class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.s: E = None
        self.p: H = None
        self.u: D = None
        self.z: D = None
        self.q: J = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: G = None
        self.u: F = None
        self.s: G = None
        self.p: H = None
        self.v: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.s: J = None
        self.u: D = None
        self.y: B = None
        self.p: H = None
        self.v: G = None
        self.t: A = None
        self.z: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: C = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: G = None
        self.u: F = None
        self.s: G = None
        self.p: H = None
        self.v: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: I = None
        self.s: J = None
        self.u: D = None
        self.y: B = None
        self.p: H = None
        self.v: G = None
        self.t: A = None
        self.z: J = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: A = None
        self.s: C = None
        self.txt = txt

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

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

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

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

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