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

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.s: F = None
        self.r: F = None
        self.p: G = None
        self.q: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: E = None
        self.u: I = None
        self.o: D = None
        self.p: E = None
        self.s: F = None
        self.t: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: D = None
        self.p: F = None
        self.v: G = None
        self.o: H = None
        self.z: G = None
        self.s: H = None
        self.x: F = None
        self.t: F = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.p: F = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.x: H = None
        self.s: F = None
        self.r: F = None
        self.p: G = None
        self.q: F = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.z: H = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.s: E = None
        self.txt = txt

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

class H:
    def __init__(self, txt: str):
        self.x: I = None
        self.r: E = None
        self.u: I = None
        self.o: D = None
        self.p: E = None
        self.s: F = None
        self.t: B = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.q: D = None
        self.p: F = None
        self.v: G = None
        self.o: H = None
        self.z: G = None
        self.s: H = None
        self.x: F = None
        self.t: F = None
        self.txt = txt

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

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