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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.u: F = None
        self.o: D = None
        self.q: A = None
        self.x: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: H = None
        self.y: E = None
        self.p: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.r: H = None
        self.t: H = None
        self.v: H = None
        self.q: C = None
        self.p: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: C = None
        self.v: A = None
        self.w: A = None
        self.t: H = None
        self.txt = txt

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

k = A("k")
j = B("j")
b = C("b")
m = D("m")
l = E("l")
c = F("c")
h = G("h")
e = H("e")

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

class B:
    def __init__(self, txt: str):
        self.r: G = None
        self.u: F = None
        self.o: D = None
        self.q: A = None
        self.x: E = None
        self.txt = txt

class C:
    def __init__(self, txt: str):
        self.s: H = None
        self.y: E = None
        self.p: H = None
        self.txt = txt

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

class E:
    def __init__(self, txt: str):
        self.o: D = None
        self.r: H = None
        self.t: H = None
        self.v: H = None
        self.q: C = None
        self.p: H = None
        self.txt = txt

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

class G:
    def __init__(self, txt: str):
        self.x: C = None
        self.v: A = None
        self.w: A = None
        self.t: H = None
        self.txt = txt

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

k = A("k")
j = B("j")
b = C("b")
m = D("m")
l = E("l")
c = F("c")
h = G("h")
e = H("e")

k.u = l
k.w = e
j.r = h
j.u = c
j.o = m
j.q = k
j.x = l
b.s = e
b.p = e
b.y = l
m.u = h
m.w = h
m.r = l
m.y = l
l.o = m
l.r = e
l.t = e
l.v = e
l.p = e
l.q = b
c.y = m
c.r = h
h.x = b
h.v = k
h.w = k
h.t = e
e.s = c
e.w = b
assert b.y.q.y.o.u.v.w.txt == "e"