class A:
    def __init__(self, txt: str):
        self.p: C = None
        self.w: B = None
        self.txt = txt

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.t: G = None
        self.w: D = None
        self.o: G = None
        self.v: D = None
        self.s: G = None
        self.x: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: G = None
        self.o: G = None
        self.r: G = None
        self.y: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: H = None
        self.y: C = None
        self.p: B = None
        self.u: F = None
        self.o: F = None
        self.x: H = None
        self.v: H = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

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

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

class B:
    def __init__(self, txt: str):
        self.u: E = None
        self.t: G = None
        self.w: D = None
        self.o: G = None
        self.v: D = None
        self.s: G = None
        self.x: C = None
        self.txt = txt

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

class D:
    def __init__(self, txt: str):
        self.p: G = None
        self.o: G = None
        self.r: G = None
        self.y: G = None
        self.txt = txt

class E:
    def __init__(self, txt: str):
        self.t: H = None
        self.y: C = None
        self.p: B = None
        self.u: F = None
        self.o: F = None
        self.x: H = None
        self.v: H = None
        self.txt = txt

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

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

class H:
    def __init__(self, txt: str):
        self.x: F = None
        self.txt = txt

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

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