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

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

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

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

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

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

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

a = A("a")
b = B("b")
e = C("e")
j = D("j")
i = E("i")
m = F("m")
h = G("h")
k = D("k")

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

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

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

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

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

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

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

a = A("a")
b = B("b")
e = C("e")
j = D("j")
i = E("i")
m = F("m")
h = G("h")
k = D("k")

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