class A:
    def __init__(self, txt: str):
        self.o: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.y: F = None
        self.r: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.u: I = None
        self.t: A = None
        self.r: A = None
        self.x: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: F = None
        self.r: C = None
        self.y: B = None
        self.q: I = None
        self.v: J = None
        self.s: H = None
        self.z: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.u: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: B = None
        self.s: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: B = None
        self.q: A = None
        self.s: A = None
        self.v: E = None
        self.t: I = None
        self.p: E = None
        self.o: B = None
        self.y: G = None
        self.w: D = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: H = None
        self.y: F = None
        self.r: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: I = None
        self.u: I = None
        self.t: A = None
        self.r: A = None
        self.x: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.t: F = None
        self.r: C = None
        self.y: B = None
        self.q: I = None
        self.v: J = None
        self.s: H = None
        self.z: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.t: F = None
        self.u: F = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: B = None
        self.s: E = None
        self.txt = txt

class J:
    def __init__(self, txt: str):
        self.r: B = None
        self.q: A = None
        self.s: A = None
        self.v: E = None
        self.t: I = None
        self.p: E = None
        self.o: B = None
        self.y: G = None
        self.w: D = None
        self.txt = txt

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

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