class A:
    def __init__(self, txt: str):
        self.y: B = None
        self.w: G = None
        self.r: G = None
        self.q: J = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: H = None
        self.w: H = None
        self.t: D = None
        self.u: H = None
        self.y: E = None
        self.p: J = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.w: J = None
        self.t: B = None
        self.u: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: F = None
        self.w: F = None
        self.q: C = None
        self.txt = txt

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.q: A = None
        self.z: H = None
        self.w: H = None
        self.t: D = None
        self.u: H = None
        self.y: E = None
        self.p: J = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.w: J = None
        self.t: B = None
        self.u: C = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: F = None
        self.w: F = None
        self.q: C = None
        self.txt = txt

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

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

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

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

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