class A:
    def __init__(self, txt: str):
        self.q: G = None
        self.y: E = None
        self.t: B = None
        self.s: J = None
        self.u: F = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.p: F = None
        self.w: C = None
        self.r: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: D = None
        self.v: J = None
        self.w: A = None
        self.u: B = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: C = None
        self.y: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: A = None
        self.p: D = None
        self.v: B = None
        self.w: F = None
        self.x: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: J = None
        self.p: B = None
        self.z: B = None
        self.v: C = None
        self.x: C = None
        self.y: H = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.p: F = None
        self.w: C = None
        self.r: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.q: D = None
        self.y: D = None
        self.v: J = None
        self.w: A = None
        self.u: B = None
        self.r: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.u: C = None
        self.o: C = None
        self.y: E = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.t: A = None
        self.p: D = None
        self.v: B = None
        self.w: F = None
        self.x: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.t: J = None
        self.p: B = None
        self.z: B = None
        self.v: C = None
        self.x: C = None
        self.y: H = None
        self.txt = txt

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

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

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