class A:
    def __init__(self, txt: str):
        self.v: B = None
        self.q: E = None
        self.r: G = None
        self.s: F = None
        self.z: C = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: F = None
        self.z: A = None
        self.q: F = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: G = None
        self.v: D = None
        self.y: A = None
        self.txt = txt

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.o: E = None
        self.s: F = None
        self.z: A = None
        self.q: F = None
        self.txt = txt

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

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

class F:
    def __init__(self, txt: str):
        self.y: G = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.w: H = None
        self.p: G = None
        self.v: D = None
        self.y: A = None
        self.txt = txt

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

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

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

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