class A:
    def __init__(self, txt: str):
        self.w: F = None
        self.t: B = None
        self.u: H = None
        self.o: D = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.x: D = None
        self.z: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: A = None
        self.t: I = None
        self.q: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: E = None
        self.x: E = None
        self.o: A = None
        self.s: C = None
        self.z: A = None
        self.v: D = None
        self.y: D = None
        self.q: F = None
        self.w: D = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.x: D = None
        self.z: F = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.r: A = None
        self.t: I = None
        self.q: B = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.t: E = None
        self.x: E = None
        self.o: A = None
        self.s: C = None
        self.z: A = None
        self.v: D = None
        self.y: D = None
        self.q: F = None
        self.w: D = None
        self.txt = txt

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

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

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

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

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