class A:
    def __init__(self, txt: str):
        self.t: G = None
        self.s: G = None
        self.u: G = None
        self.z: F = None
        self.o: E = None
        self.w: I = None
        self.r: J = None
        self.y: I = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.z: I = None
        self.w: H = None
        self.v: G = None
        self.u: G = None
        self.x: A = None
        self.q: H = None
        self.o: G = None
        self.s: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.p: A = None
        self.u: I = None
        self.q: I = None
        self.x: C = None
        self.t: G = None
        self.r: A = None
        self.s: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: G = None
        self.y: A = None
        self.u: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: F = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.z: I = None
        self.w: H = None
        self.v: G = None
        self.u: G = None
        self.x: A = None
        self.q: H = None
        self.o: G = None
        self.s: A = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.p: A = None
        self.u: I = None
        self.q: I = None
        self.x: C = None
        self.t: G = None
        self.r: A = None
        self.s: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: G = None
        self.y: A = None
        self.u: G = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: F = None
        self.txt = txt

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

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