class A:
    def __init__(self, txt: str):
        self.u: D = None
        self.r: D = None
        self.t: F = None
        self.w: I = None
        self.p: E = None
        self.s: F = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.t: H = None
        self.x: F = None
        self.w: C = None
        self.p: G = None
        self.y: F = None
        self.v: B = None
        self.u: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: I = None
        self.q: J = None
        self.w: H = None
        self.p: G = None
        self.y: A = None
        self.r: F = None
        self.s: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.q: A = None
        self.v: H = None
        self.t: F = None
        self.y: C = None
        self.w: A = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: F = None
        self.x: E = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.r: F = None
        self.t: H = None
        self.x: F = None
        self.w: C = None
        self.p: G = None
        self.y: F = None
        self.v: B = None
        self.u: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.o: F = None
        self.v: I = None
        self.q: J = None
        self.w: H = None
        self.p: G = None
        self.y: A = None
        self.r: F = None
        self.s: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: J = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.z: C = None
        self.q: A = None
        self.v: H = None
        self.t: F = None
        self.y: C = None
        self.w: A = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.v: F = None
        self.x: E = None
        self.txt = txt

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

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

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