class A:
    def __init__(self, txt: str):
        self.z: C = None
        self.p: I = None
        self.y: D = None
        self.q: C = None
        self.w: I = None
        self.t: I = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: E = None
        self.q: E = None
        self.v: E = None
        self.r: F = None
        self.y: G = None
        self.x: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.w: I = None
        self.o: C = None
        self.u: H = None
        self.t: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: H = None
        self.p: F = None
        self.v: E = None
        self.o: H = None
        self.w: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: C = None
        self.r: C = None
        self.y: H = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.p: D = None
        self.t: C = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.t: E = None
        self.q: E = None
        self.v: E = None
        self.r: F = None
        self.y: G = None
        self.x: F = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.p: H = None
        self.w: I = None
        self.o: C = None
        self.u: H = None
        self.t: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.q: H = None
        self.s: H = None
        self.p: F = None
        self.v: E = None
        self.o: H = None
        self.w: B = None
        self.txt = txt

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

class I:
    def __init__(self, txt: str):
        self.z: C = None
        self.r: C = None
        self.y: H = None
        self.txt = txt

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

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