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

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

class C:
    def __init__(self, txt: str):
        self.y: H = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: C = None
        self.x: G = None
        self.y: D = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.r: C = None
        self.u: C = None
        self.q: E = None
        self.z: J = None
        self.p: A = None
        self.v: J = None
        self.s: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: A = None
        self.q: G = None
        self.p: J = None
        self.u: A = None
        self.o: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: A = None
        self.x: H = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.y: H = None
        self.q: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: C = None
        self.z: C = None
        self.x: G = None
        self.y: D = None
        self.t: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.y: A = None
        self.r: C = None
        self.u: C = None
        self.q: E = None
        self.z: J = None
        self.p: A = None
        self.v: J = None
        self.s: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.y: A = None
        self.q: G = None
        self.p: J = None
        self.u: A = None
        self.o: G = None
        self.txt = txt

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

class J:
    def __init__(self, txt: str):
        self.u: A = None
        self.x: H = None
        self.txt = txt

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

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