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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: H = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: G = None
        self.q: G = None
        self.p: A = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.y: F = None
        self.u: F = None
        self.o: F = None
        self.w: I = None
        self.v: E = None
        self.z: H = None
        self.p: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.t: I = None
        self.x: H = None
        self.u: G = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.u: D = None
        self.y: G = None
        self.q: G = None
        self.p: A = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.y: F = None
        self.u: F = None
        self.o: F = None
        self.w: I = None
        self.v: E = None
        self.z: H = None
        self.p: H = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.o: B = None
        self.txt = txt

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

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

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