class A:
    def __init__(self, txt: str):
        self.u: F = None
        self.r: G = None
        self.w: B = None
        self.s: C = None
        self.y: G = None
        self.z: E = None
        self.q: G = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.w: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.p: H = None
        self.txt = txt

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

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

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

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

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

class D:
    def __init__(self, txt: str):
        self.w: G = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.p: H = None
        self.txt = txt

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

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

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