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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.z: F = None
        self.p: F = None
        self.u: A = None
        self.y: F = None
        self.q: A = None
        self.r: D = None
        self.t: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: F = None
        self.v: H = None
        self.z: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.r: I = None
        self.txt = txt

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

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

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

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

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

class B:
    def __init__(self, txt: str):
        self.s: G = None
        self.z: F = None
        self.p: F = None
        self.u: A = None
        self.y: F = None
        self.q: A = None
        self.r: D = None
        self.t: F = None
        self.txt = txt

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

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

class E:
    def __init__(self, txt: str):
        self.u: F = None
        self.q: F = None
        self.v: H = None
        self.z: D = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.u: A = None
        self.r: I = None
        self.txt = txt

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

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

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

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

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