class A:
    def __init__(self, txt: str):
        self.v: H = None
        self.t: E = None
        self.q: G = None
        self.o: G = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.t: E = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.t: G = None
        self.p: D = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.o: C = None
        self.s: C = None
        self.t: A = None
        self.z: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: A = None
        self.w: E = None
        self.txt = txt

a = A("a")
d = B("d")
f = C("f")
e = D("e")
m = E("m")
i = F("i")
b = G("b")
h = H("h")
k = E("k")
l = E("l")

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

class B:
    def __init__(self, txt: str):
        self.w: E = None
        self.t: E = None
        self.s: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.z: H = None
        self.s: B = None
        self.t: G = None
        self.p: D = None
        self.txt = txt

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

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

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

class G:
    def __init__(self, txt: str):
        self.v: A = None
        self.o: C = None
        self.s: C = None
        self.t: A = None
        self.z: F = None
        self.txt = txt

class H:
    def __init__(self, txt: str):
        self.s: A = None
        self.w: E = None
        self.txt = txt

a = A("a")
d = B("d")
f = C("f")
e = D("e")
m = E("m")
i = F("i")
b = G("b")
h = H("h")
k = E("k")
l = E("l")

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