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

class B:
    def __init__(self, txt: str):
        self.r: I = None
        self.z: A = None
        self.o: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: B = None
        self.r: B = None
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: H = None
        self.o: C = None
        self.w: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: D = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.u: A = None
        self.s: E = None
        self.w: E = None
        self.x: B = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.r: I = None
        self.z: A = None
        self.o: I = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.u: B = None
        self.r: B = None
        self.o: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: H = None
        self.o: C = None
        self.w: C = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.w: C = None
        self.y: D = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: F = None
        self.u: A = None
        self.s: E = None
        self.w: E = None
        self.x: B = None
        self.txt = txt

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

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