class A:
    def __init__(self, txt: str):
        self.s: B = None
        self.r: E = None
        self.x: I = None
        self.z: D = None
        self.y: B = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.x: F = None
        self.q: B = None
        self.w: H = None
        self.u: I = None
        self.p: E = None
        self.o: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: D = None
        self.s: I = None
        self.q: J = None
        self.r: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: E = None
        self.p: D = None
        self.r: E = None
        self.s: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: E = None
        self.z: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: G = None
        self.r: A = None
        self.u: A = None
        self.x: H = None
        self.q: F = None
        self.t: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: I = None
        self.q: C = None
        self.s: C = None
        self.txt = txt

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.x: F = None
        self.q: B = None
        self.w: H = None
        self.u: I = None
        self.p: E = None
        self.o: H = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.x: D = None
        self.s: I = None
        self.q: J = None
        self.r: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: E = None
        self.p: D = None
        self.r: E = None
        self.s: J = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.s: C = None
        self.r: E = None
        self.z: J = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.s: G = None
        self.r: A = None
        self.u: A = None
        self.x: H = None
        self.q: F = None
        self.t: J = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.x: I = None
        self.q: C = None
        self.s: C = None
        self.txt = txt

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

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