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

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

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

class D:
    def __init__(self, txt: str):
        self.o: H = None
        self.r: E = None
        self.y: H = None
        self.s: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: E = None
        self.o: G = None
        self.v: D = None
        self.p: E = None
        self.u: I = None
        self.txt = txt

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

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

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.o: H = None
        self.r: E = None
        self.y: H = None
        self.s: F = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.w: D = None
        self.s: E = None
        self.o: G = None
        self.v: D = None
        self.p: E = None
        self.u: I = None
        self.txt = txt

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

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

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

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

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