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

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

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

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.z: B = None
        self.r: B = None
        self.w: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

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

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

f = A("f")
k = B("k")
n = C("n")
l = D("l")
g = E("g")
a = F("a")
d = G("d")
j = H("j")

f.w = n
f.r = n
f.t = k
f.p = j
f.x = j
f.y = l
f.v = a
k.w = f
k.z = n
k.r = n
k.u = g
k.s = g
k.y = a
k.p = a
k.t = j
n.r = l
n.s = l
n.v = d
n.q = g
n.y = g
l.o = d
l.z = k
l.r = k
l.w = g
g.r = k
g.z = n
a.w = k
d.p = l
d.w = l
d.y = l
d.x = g
d.v = j
d.q = k
j.r = n
j.p = n
j.s = n
j.z = g
j.w = f
j.x = d
j.o = a
j.v = k
assert a.w.t.x.v.txt == "
class A:
    def __init__(self, txt: str):
        self.w: C = None
        self.t: B = None
        self.p: H = None
        self.y: D = None
        self.v: F = None
        self.r: C = None
        self.x: H = None
        self.txt = txt

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

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

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.z: B = None
        self.r: B = None
        self.w: E = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.r: B = None
        self.z: C = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.w: B = None
        self.txt = txt

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

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

f = A("f")
k = B("k")
n = C("n")
l = D("l")
g = E("g")
a = F("a")
d = G("d")
j = H("j")

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