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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.y: D = None
        self.q: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: E = None
        self.x: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.z: E = None
        self.t: H = None
        self.o: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: C = None
        self.z: D = None
        self.u: C = None
        self.x: C = None
        self.p: J = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.t: F = None
        self.y: D = None
        self.p: G = None
        self.w: B = None
        self.o: F = None
        self.q: C = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: G = None
        self.x: C = None
        self.v: B = None
        self.y: I = None
        self.u: I = None
        self.t: A = None
        self.z: G = None
        self.o: B = None
        self.r: D = None
        self.s: A = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.y: D = None
        self.q: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.v: E = None
        self.x: B = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.z: E = None
        self.t: H = None
        self.o: C = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: G = None
        self.w: C = None
        self.z: D = None
        self.u: C = None
        self.x: C = None
        self.p: J = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.v: C = None
        self.t: F = None
        self.y: D = None
        self.p: G = None
        self.w: B = None
        self.o: F = None
        self.q: C = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.w: G = None
        self.x: C = None
        self.v: B = None
        self.y: I = None
        self.u: I = None
        self.t: A = None
        self.z: G = None
        self.o: B = None
        self.r: D = None
        self.s: A = None
        self.txt = txt

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

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