class A:
    def __init__(self, txt: str):
        self.y: C = None
        self.v: B = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.y: E = None
        self.q: G = None
        self.t: B = None
        self.s: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.o: A = None
        self.r: F = None
        self.u: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: E = None
        self.z: E = None
        self.o: H = None
        self.u: H = None
        self.v: D = None
        self.r: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.v: C = None
        self.r: E = None
        self.o: C = None
        self.t: F = None
        self.q: C = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.z: B = None
        self.s: A = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: E = None
        self.y: E = None
        self.q: G = None
        self.t: B = None
        self.s: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.w: H = None
        self.o: A = None
        self.r: F = None
        self.u: A = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.q: E = None
        self.z: E = None
        self.o: H = None
        self.u: H = None
        self.v: D = None
        self.r: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.v: C = None
        self.r: E = None
        self.o: C = None
        self.t: F = None
        self.q: C = None
        self.txt = txt

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

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