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

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.y: A = None
        self.o: D = None
        self.t: D = None
        self.x: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: B = None
        self.y: A = None
        self.p: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: H = None
        self.s: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: E = None
        self.x: H = None
        self.y: A = None
        self.p: C = None
        self.txt = txt

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

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

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

class B:
    def __init__(self, txt: str):
        self.s: C = None
        self.y: A = None
        self.o: D = None
        self.t: D = None
        self.x: A = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.q: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.v: E = None
        self.t: B = None
        self.y: A = None
        self.p: B = None
        self.txt = txt

class F:
    def __init__(self, txt: str):
        self.p: A = None
        self.v: H = None
        self.s: H = None
        self.txt = txt

class G:
    def __init__(self, txt: str):
        self.t: C = None
        self.z: E = None
        self.x: H = None
        self.y: A = None
        self.p: C = None
        self.txt = txt

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

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

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