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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: J = None
        self.w: C = None
        self.r: F = None
        self.s: J = None
        self.v: C = None
        self.p: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: G = None
        self.z: B = None
        self.o: E = None
        self.x: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: I = None
        self.t: I = None
        self.r: F = None
        self.s: I = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: G = None
        self.r: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.z: B = None
        self.y: G = None
        self.r: I = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.x: G = None
        self.o: J = None
        self.w: C = None
        self.r: F = None
        self.s: J = None
        self.v: C = None
        self.p: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.x: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.r: G = None
        self.z: B = None
        self.o: E = None
        self.x: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.o: F = None
        self.u: I = None
        self.t: I = None
        self.r: F = None
        self.s: I = None
        self.y: D = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: G = None
        self.r: J = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.z: B = None
        self.y: G = None
        self.r: I = None
        self.txt = txt

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

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