class A:
    def __init__(self, txt: str):
        self.y: G = None
        self.q: B = None
        self.o: E = None
        self.u: B = None
        self.w: E = None
        self.txt = txt

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.r: E = None
        self.txt = txt

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

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

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

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

i = A("i")
k = B("k")
l = C("l")
m = D("m")
f = E("f")
n = F("n")
d = G("d")
b = H("b")
e = C("e")
h = E("h")

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

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

class C:
    def __init__(self, txt: str):
        self.v: A = None
        self.t: D = None
        self.txt = txt

class D:
    def __init__(self, txt: str):
        self.z: C = None
        self.r: E = None
        self.txt = txt

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

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

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

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

i = A("i")
k = B("k")
l = C("l")
m = D("m")
f = E("f")
n = F("n")
d = G("d")
b = H("b")
e = C("e")
h = E("h")

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