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

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

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

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

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.x: I = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.r: F = None
        self.z: C = None
        self.q: I = None
        self.o: F = None
        self.s: C = None
        self.v: H = None
        self.w: J = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: B = None
        self.y: A = None
        self.q: I = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.p: F = None
        self.x: I = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: C = None
        self.r: F = None
        self.z: C = None
        self.q: I = None
        self.o: F = None
        self.s: C = None
        self.v: H = None
        self.w: J = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: H = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: B = None
        self.y: A = None
        self.q: I = None
        self.txt = txt

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

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