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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.y: G = None
        self.s: E = None
        self.r: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: E = None
        self.txt = txt

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

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

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

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

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

class E:
    def __init__(self, txt: str):
        self.u: D = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.u: C = None
        self.y: G = None
        self.s: E = None
        self.r: I = None
        self.txt = txt

class I:
    def __init__(self, txt: str):
        self.y: E = None
        self.txt = txt

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

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