class A:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: E = None
        self.v: E = None
        self.x: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: C = None
        self.r: C = None
        self.v: G = None
        self.x: C = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.u: G = None
        self.z: C = None
        self.r: D = None
        self.w: E = None
        self.txt = txt

d = A("d")
f = B("f")
a = C("a")
j = D("j")
h = E("h")
c = F("c")
n = G("n")
b = H("b")
e = F("e")
i = G("i")

d.v = b
f.o = h
f.v = h
f.x = b
a.v = f
a.u = h
a.y = c
a.t = b
j.y = a
j.r = a
j.x = a
j.v = n
j.z = d
h.q = a
c.y = j
n.v = a
n.s = f
n.o = f
n.w = i
n.t = i
n.u = c
n.r = j
n.x = j
b.t = n
b.u = i
b.z = a
b.r = j
b.w = h
e.y = j
i.v = a
i.s = f
i.o = f
i.w = n
i.t = n
i.u = c
i.r = j
i.x = j
assert d.v.r.v.t.u.y.z.v.txt == "
class A:
    def __init__(self, txt: str):
        self.v: H = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.o: E = None
        self.v: E = None
        self.x: H = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.y: C = None
        self.r: C = None
        self.v: G = None
        self.x: C = None
        self.z: A = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.q: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.y: D = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.t: G = None
        self.u: G = None
        self.z: C = None
        self.r: D = None
        self.w: E = None
        self.txt = txt

d = A("d")
f = B("f")
a = C("a")
j = D("j")
h = E("h")
c = F("c")
n = G("n")
b = H("b")
e = F("e")
i = G("i")

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