class A:
    def __init__(self, txt: str):
        self.u: H = None
        self.v: E = None
        self.q: E = None
        self.p: C = None
        self.s: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: E = None
        self.x: E = None
        self.y: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.t: A = None
        self.x: C = None
        self.w: B = None
        self.r: G = None
        self.q: E = None
        self.p: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.q: D = None
        self.x: E = None
        self.r: A = None
        self.t: F = None
        self.z: E = None
        self.s: C = None
        self.y: E = None
        self.txt = txt

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

k.u = a
k.v = l
k.q = l
k.p = e
k.s = e
j.t = l
j.x = l
j.y = k
e.u = m
m.q = k
m.x = k
m.t = k
m.w = k
m.s = j
m.v = d
m.p = b
m.z = n
m.u = e
l.t = m
l.x = m
n.z = j
n.w = j
n.t = k
n.x = e
n.r = b
n.q = l
n.p = l
b.q = e
b.t = k
a.y = n
d.q = m
d.x = l
d.z = l
d.y = l
d.r = k
d.t = n
d.s = e
assert l.x.v.r.q.t.z.r.t.txt == "
class A:
    def __init__(self, txt: str):
        self.u: H = None
        self.v: E = None
        self.q: E = None
        self.p: C = None
        self.s: C = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.t: E = None
        self.x: E = None
        self.y: A = None
        self.txt = txt

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

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

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

class F:
    def __init__(self, txt: str):
        self.z: B = None
        self.t: A = None
        self.x: C = None
        self.w: B = None
        self.r: G = None
        self.q: E = None
        self.p: E = None
        self.txt = txt

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

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

class I:
    def __init__(self, txt: str):
        self.q: D = None
        self.x: E = None
        self.r: A = None
        self.t: F = None
        self.z: E = None
        self.s: C = None
        self.y: E = None
        self.txt = txt

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

k.u = a
k.v = l
k.q = l
k.p = e
k.s = e
j.t = l
j.x = l
j.y = k
e.u = m
m.q = k
m.x = k
m.t = k
m.w = k
m.s = j
m.v = d
m.p = b
m.z = n
m.u = e
l.t = m
l.x = m
n.z = j
n.w = j
n.t = k
n.x = e
n.r = b
n.q = l
n.p = l
b.q = e
b.t = k
a.y = n
d.q = m
d.x = l
d.z = l
d.y = l
d.r = k
d.t = n
d.s = e
assert l.x.v.r.q.t.z.r.t.txt == "k"