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

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

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

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.u: G = None
        self.x: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: E = None
        self.s: D = None
        self.v: D = None
        self.u: B = None
        self.txt = txt

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

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

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.s: E = None
        self.u: G = None
        self.x: C = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.r: E = None
        self.s: D = None
        self.v: D = None
        self.u: B = None
        self.txt = txt

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

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

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

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

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