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

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.u: C = None
        self.y: H = None
        self.o: A = None
        self.t: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: A = None
        self.v: H = None
        self.w: A = None
        self.s: B = None
        self.y: I = None
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: B = None
        self.s: H = None
        self.u: G = None
        self.z: A = None
        self.x: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: I = None
        self.w: I = None
        self.s: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: B = None
        self.v: G = None
        self.u: C = None
        self.q: C = None
        self.w: C = None
        self.s: D = None
        self.o: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: H = None
        self.q: E = None
        self.z: B = None
        self.u: C = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.s: I = None
        self.u: C = None
        self.y: H = None
        self.o: A = None
        self.t: D = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.q: B = None
        self.t: A = None
        self.v: H = None
        self.w: A = None
        self.s: B = None
        self.y: I = None
        self.x: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.v: B = None
        self.s: H = None
        self.u: G = None
        self.z: A = None
        self.x: D = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.q: I = None
        self.o: I = None
        self.w: I = None
        self.s: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: B = None
        self.v: G = None
        self.u: C = None
        self.q: C = None
        self.w: C = None
        self.s: D = None
        self.o: C = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.o: H = None
        self.q: E = None
        self.z: B = None
        self.u: C = None
        self.txt = txt

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

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