class A:
    def __init__(self, txt: str):
        self.z: G = None
        self.u: E = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: H = None
        self.s: H = None
        self.x: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.y: E = None
        self.u: C = None
        self.r: F = None
        self.v: B = None
        self.t: E = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: B = None
        self.x: E = None
        self.z: G = None
        self.txt = txt

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

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

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

class C:
    def __init__(self, txt: str):
        self.v: D = None
        self.o: H = None
        self.s: H = None
        self.x: H = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.o: G = None
        self.y: E = None
        self.u: C = None
        self.r: F = None
        self.v: B = None
        self.t: E = None
        self.txt = txt

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

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

class G:
    def __init__(self, txt: str):
        self.v: C = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.u: D = None
        self.p: B = None
        self.x: E = None
        self.z: G = None
        self.txt = txt

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

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