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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: C = None
        self.v: A = None
        self.o: E = None
        self.x: C = None
        self.txt = txt

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

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

h = A("h")
a = B("a")
e = C("e")
f = D("f")
b = E("b")
c = F("c")
i = G("i")
g = H("g")
k = G("k")

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

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

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

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

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

class F:
    def __init__(self, txt: str):
        self.t: C = None
        self.v: A = None
        self.o: E = None
        self.x: C = None
        self.txt = txt

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

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

h = A("h")
a = B("a")
e = C("e")
f = D("f")
b = E("b")
c = F("c")
i = G("i")
g = H("g")
k = G("k")

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