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

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

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.o: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: A = None
        self.v: A = None
        self.u: C = None
        self.x: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: A = None
        self.u: A = None
        self.v: G = None
        self.r: C = None
        self.z: G = None
        self.o: E = None
        self.s: C = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: A = None
        self.o: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.q: I = None
        self.txt = txt

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

class F:
    def __init__(self, txt: str):
        self.t: A = None
        self.v: A = None
        self.u: C = None
        self.x: D = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: A = None
        self.u: A = None
        self.v: G = None
        self.r: C = None
        self.z: G = None
        self.o: E = None
        self.s: C = None
        self.txt = txt

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

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

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

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