class A:
    def __init__(self, txt: str):
        self.u: C = None
        self.r: G = None
        self.s: H = None
        self.v: I = None
        self.q: I = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.s: I = None
        self.r: J = None
        self.x: A = None
        self.p: F = None
        self.z: G = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: G = None
        self.s: H = None
        self.z: F = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: J = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: I = None
        self.r: J = None
        self.x: A = None
        self.p: F = None
        self.z: G = None
        self.u: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.u: G = None
        self.s: H = None
        self.z: F = None
        self.txt = txt

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

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

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

class I:
    def __init__(self, txt: str):
        self.u: E = None
        self.q: J = None
        self.txt = txt

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

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

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