class A:
    def __init__(self, txt: str):
        self.z: B = None
        self.u: F = None
        self.r: F = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.q: J = None
        self.u: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: G = None
        self.y: A = None
        self.s: H = None
        self.t: H = None
        self.x: D = None
        self.w: F = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: C = None
        self.u: F = None
        self.y: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: J = None
        self.w: H = None
        self.q: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.w: B = None
        self.s: G = None
        self.o: J = None
        self.u: B = None
        self.x: J = None
        self.v: G = None
        self.p: E = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.w: G = None
        self.q: J = None
        self.u: D = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.p: G = None
        self.y: A = None
        self.s: H = None
        self.t: H = None
        self.x: D = None
        self.w: F = None
        self.u: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.s: C = None
        self.u: F = None
        self.y: I = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: E = None
        self.v: J = None
        self.w: H = None
        self.q: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.w: B = None
        self.s: G = None
        self.o: J = None
        self.u: B = None
        self.x: J = None
        self.v: G = None
        self.p: E = None
        self.txt = txt

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

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

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