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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: C = None
        self.w: C = None
        self.u: H = None
        self.t: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: H = None
        self.s: J = None
        self.u: J = None
        self.v: J = None
        self.r: G = None
        self.x: B = None
        self.z: F = None
        self.o: J = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: F = None
        self.t: H = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.x: H = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.s: C = None
        self.w: C = None
        self.u: H = None
        self.t: E = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.r: J = None
        self.s: C = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.t: H = None
        self.s: J = None
        self.u: J = None
        self.v: J = None
        self.r: G = None
        self.x: B = None
        self.z: F = None
        self.o: J = None
        self.txt = txt

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

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

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