class A:
    def __init__(self, txt: str):
        self.t: I = None
        self.z: B = None
        self.v: D = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: I = None
        self.q: E = None
        self.r: A = None
        self.w: B = None
        self.t: H = None
        self.p: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: F = None
        self.r: F = None
        self.o: A = None
        self.u: I = None
        self.s: B = None
        self.v: E = None
        self.txt = txt

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

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

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

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

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

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

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

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

class C:
    def __init__(self, txt: str):
        self.v: I = None
        self.q: E = None
        self.r: A = None
        self.w: B = None
        self.t: H = None
        self.p: G = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.w: F = None
        self.r: F = None
        self.o: A = None
        self.u: I = None
        self.s: B = None
        self.v: E = None
        self.txt = txt

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

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

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

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

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

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

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