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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: I = None
        self.u: F = None
        self.x: H = None
        self.s: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: G = None
        self.y: C = None
        self.w: A = None
        self.r: A = None
        self.t: B = None
        self.p: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.t: A = None
        self.q: C = None
        self.r: C = None
        self.w: A = None
        self.o: H = None
        self.x: C = None
        self.v: F = None
        self.z: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.x: C = None
        self.w: B = None
        self.q: D = None
        self.y: G = None
        self.v: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.txt = txt

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.v: D = None
        self.r: I = None
        self.u: F = None
        self.x: H = None
        self.s: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.x: G = None
        self.y: C = None
        self.w: A = None
        self.r: A = None
        self.t: B = None
        self.p: B = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.s: D = None
        self.t: A = None
        self.q: C = None
        self.r: C = None
        self.w: A = None
        self.o: H = None
        self.x: C = None
        self.v: F = None
        self.z: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.o: D = None
        self.x: C = None
        self.w: B = None
        self.q: D = None
        self.y: G = None
        self.v: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: B = None
        self.txt = txt

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

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

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

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