class A:
    def __init__(self, txt: str):
        self.p: F = None
        self.y: C = None
        self.q: F = None
        self.u: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: C = None
        self.u: E = None
        self.t: F = None
        self.p: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: E = None
        self.v: F = None
        self.t: G = None
        self.o: B = None
        self.s: F = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.y: A = None
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.u: A = None
        self.o: A = None
        self.t: C = None
        self.txt = txt

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

g = A("g")
f = B("f")
e = C("e")
k = D("k")
c = E("c")
d = F("d")
l = G("l")
i = B("i")
a = G("a")
m = G("m")

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

class B:
    def __init__(self, txt: str):
        self.w: C = None
        self.u: E = None
        self.t: F = None
        self.p: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: E = None
        self.v: F = None
        self.t: G = None
        self.o: B = None
        self.s: F = None
        self.y: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.r: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.y: A = None
        self.s: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: G = None
        self.r: B = None
        self.u: A = None
        self.o: A = None
        self.t: C = None
        self.txt = txt

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

g = A("g")
f = B("f")
e = C("e")
k = D("k")
c = E("c")
d = F("d")
l = G("l")
i = B("i")
a = G("a")
m = G("m")

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